I think you misunderstand the current usage of the SUBTOTAL function. When it talks about hidden cells it means hidden, not filtered. It will ignore filtered values for both 9 and 109 but with 109 if there are some additional hidden rows in there, for example, they will also get ignored...but 9 will still include them.
To get what I THINK you are looking for:
IF you are using filtering
SUM(range) to get the total count regardless of filtering or hiding
SUBTOTAL(9,range) to get the filtered count
IF you are hiding rows programmatically (for example)
SUBTOTAL(9,range) to get the full count
SUBTOTAL(109,range) to get the full count minus any hidden rows
Alistair