BUG: `__array_ufunc__` with for functions with side-effects depends on `_data`
- [x] I have checked that this issue has not already been reported.

- [x] I have confirmed this bug exists on the latest version of pandas.

- [ ] (optional) I have confirmed this bug exists on the master branch of pandas.

IIUC for pandas extension arrays, for each location where `_mask` is `True`, the value of `_data` should be irrelevant. However this is not the case for `__array_ufunc__`:

```python
In [1]: import pandas as pd
   ...: import numpy as np
   ...: 
   ...: arr = pd.array([True, False, pd.NA], dtype="boolean")
   ...: arr
Out[1]: 
<BooleanArray>
[True, False, <NA>]
Length: 3, dtype: boolean

In [2]: y = np.ones(3, bool)
   ...: out = np.ones(3, bool)
   ...: 
   ...: np.logical_and(arr, y, out=out)
   ...: out
Out[2]: array([ True, False, False])

In [3]: arr._data[2] = True  # This does not change arr since arr._mask[2] = True
   ...: 
   ...: np.logical_and(arr, y, out=out)
   ...: out
Out[3]: array([ True, False,  True])
```

Relevant code:
https://github.com/pandas-dev/pandas/blob/17ecb56c219d8d01399faffcffa8f059ecf6fd45/pandas/core/arrays/boolean.py#L366-L390

Here we are calling 
```python
result = np.logical_and(arr._data, y, out=out)
return BooleanArray(result, arr._mask)
```
which adjusts `out` in-place, ignoring the mask and depending on `arr._data[2]`.

This issue shows how this might be an issue:
https://github.com/numpy/numpy/issues/19374
#### Output of ``pd.show_versions()``

<details>
In [4]: pd.show_versions()

INSTALLED VERSIONS
------------------
commit           : 2cb96529396d93b46abab7bbc73a208e708c642e
python           : 3.9.2.final.0
python-bits      : 64
OS               : Linux
OS-release       : 5.4.0-74-generic
Version          : #83-Ubuntu SMP Sat May 8 02:35:39 UTC 2021
machine          : x86_64
processor        : x86_64
byteorder        : little
LC_ALL           : None
LANG             : en_US.UTF-8
LOCALE           : en_US.UTF-8

pandas           : 1.2.4
numpy            : 1.21.0
pytz             : 2021.1
dateutil         : 2.8.1
pip              : 21.1.1
setuptools       : 49.6.0.post20210108
Cython           : None
pytest           : 6.2.3
hypothesis       : None
sphinx           : 3.5.4
blosc            : None
feather          : None
xlsxwriter       : None
lxml.etree       : None
html5lib         : None
pymysql          : None
psycopg2         : None
jinja2           : 2.11.3
IPython          : 7.23.0
pandas_datareader: None
bs4              : None
bottleneck       : None
fsspec           : 2021.04.0
fastparquet      : None
gcsfs            : None
matplotlib       : 3.4.2
numexpr          : None
odfpy            : None
openpyxl         : None
pandas_gbq       : None
pyarrow          : 4.0.1
pyxlsb           : None
s3fs             : None
scipy            : 1.6.3
sqlalchemy       : None
tables           : None
tabulate         : 0.8.9
xarray           : None
xlrd             : None
xlwt             : None
numba            : None


</details>
