The `getaddressesbylabel` API spends a lot more time than the `getaddressesbyaccount` API.

I generated addresses by the `getnewaddress` API, then, I measured time that the `getaddressesby*` API spends. It seems the algorithm of the `getaddressesbylabel` API takes **O(N ^ 2)** time! The results of my survey are as follows.

### getaddressesbylabel

bitcoind v0.17.1 on Ubuntu 16.04 (AWS EC2 t3.large)

#### 11,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbylabel ""
# (omitted)
real    0m1.230s # 1.2s
user    0m0.044s
sys 0m0.048s
```

#### 111,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbylabel ""
# (omitted)
real    1m37.027s # 97.0s
user    0m0.408s
sys 0m0.544s
```

#### 211,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbylabel ""
# (omitted)
real    6m3.727s # 363.7s
user    0m0.800s
sys 0m0.900s
```

### getaddressesbyaccount

bitcoind v0.16.3 on Ubuntu 16.04 (AWS EC2 t3.large)

#### 11,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbyaccount ""
# (omitted)
real    0m0.500s # 0.5s
user    0m0.092s
sys 0m0.160s
```

#### 111,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbyaccount ""
# (omitted)
real    0m1.361s # 1.4s
user    0m0.168s
sys 0m0.348s
```

#### 211,001 addresses

```sh
time sudo /usr/local/bin/bitcoin-cli -conf=/etc/bitcoin/bitcoin.conf getaddressesbyaccount ""
# (omitted)
real    0m2.220s # 2.2s
user    0m0.384s
sys 0m0.532s
```

{
    std::shared_ptr<CWallet> const wallet = GetWalletForJSONRPCRequest(request);
    CWallet* const pwallet = wallet.get();
    if (!EnsureWalletIsAvailable(pwallet, request.fHelp))
        return NullUniValue;
    if (request.fHelp || request.params.size() < 1 || request.params.size() > 2) {
        throw std::runtime_error(
            RPCHelpMan{"bumpfee",
                "\nBumps the fee of an opt-in-RBF transaction T, replacing it with a new transaction B.\n"
                "An opt-in RBF transaction with the given txid must be in the wallet.\n"
                "The command will pay the additional fee by decreasing (or perhaps removing) its change output.\n"
                "If the change output is not big enough to cover the increased fee, the command will currently fail\n"
                "instead of adding new inputs to compensate. (A future implementation could improve this.)\n"
                "The command will fail if the wallet or mempool contains a transaction that spends one of T's outputs.\n"
                "By default, the new fee will be calculated automatically using estimatesmartfee.\n"
                "The user can specify a confirmation target for estimatesmartfee.\n"
                "Alternatively, the user can specify totalFee, or use RPC settxfee to set a higher fee rate.\n"
                "At a minimum, the new fee rate must be high enough to pay an additional new relay fee (incrementalfee\n"
                "returned by getnetworkinfo) to enter the node's mempool.\n",
                {
                    {"txid", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "The txid to be bumped"},
                    {"options", RPCArg::Type::OBJ, RPCArg::Optional::OMITTED_NAMED_ARG, "",