For instance, I don't understand why you would want to have an edge sensitive interrupt masked. True that masking it isn't the same as disabling and interrupt in the PORT PCR register but if your software isn't ready to handle that interrupt why would you want to keep that interrupt record?
Whether a request from an external device is pending has nothing to do with whether I'm ready to handle the request. Consider the obvious case of a device that processes bytes received from the program in some way, and indicates when it has finished processing a byte and is ready for another by pulsing an interrupt line. Just because it's ready for a byte doesn't mean I've got one to give it. The clean and simple way to handle that is to mask the interrupt when I no longer have any byte to issue to it. When the interrupt occurs, it just remains pending until I have another byte, at which point I can just unmask the interrupt, and bang, the interrupt happens and sends the next byte. If I have a software FIFO, the interrupt handler itself can do the masking when the FIFO becomes empty.
And even if you had a need, you can enable an interrupt on the pin without enabling the Port in the NVIC and the interrupt routing wouldn't be executed.
That would be exactly what I want, except that the single NVIC input is shared by all the pins on a port. With all the other devices, the individual interrupts that are combined into a single NVIC input have individual mask bits as part of the design of the device. (See for instance the UART, or SPI, or I2C.) That's the normal way of doing things.
Otherwise, you could setup a counter variable to keep track of when the interrupt has been taken. Is it really that messy to setup a counter variable to keep track of when an edge sensitive interrupt has occurred?
For edge-sensitive interrupts, it only takes a flag, not a counter. And that is indeed what I'm doing. It's two bits in software, a mask flag and a pending flag, and a few lines of code. When an interrupt occurs, the handler services the interrupt if the mask is clear, or sets the pending flag if the mask is set. When something clears the mask, it checks the pending flag, and simulates the "interrupt" at that time.
But it's only that simple if I require all inputs on the port to be edge-sensitive. If I wanted to construct a truly general purpose software wrapper for port interrupts, which handled both edge and level sensitive interrupts, it would have to treat them differently. It would treat edge-sensitive interrupts as described abbove, while level-sensitive interrupts would use the built-in disable mechanism, but would need a software record of what mode to put them in (high level or low level) when re-enabling them. That's pretty messy.
And the stock ExtInt PE component doesn't do any of this. It only really works for level-sensitive interrupts.
Oh, and another reason for being able to mask an edge-sensitive interrupt without disabling it is so that the request can be polled rather than invoking an interrupt handler, while still allowing other pin interrupts to be enabled.
Bottom line: to be consistent with all the other devices, all interrupts that are funneled through a single NVIC input should have independent masks. That's nothing more than another 32-bit register and 32 AND gates.