diff options
author | Anup Patel <anup.patel@wdc.com> | 2020-03-11 19:25:24 +0530 |
---|---|---|
committer | Anup Patel <anup@brainfault.org> | 2020-03-13 12:18:51 +0530 |
commit | eeae3d95827ec33e74d853596b89ee49d83ff751 (patch) | |
tree | f4e59fba89bf08c118d57ef5bddc806bf11c1c87 /Makefile | |
parent | f92147c2b2fd01bd32debe4d6cb0375705dceeac (diff) |
firmware: fw_base: Optimize _hartid_to_scratch() implementation
This patch optimizes _hartid_to_scratch() in following ways:
1. Use caller saved registers instead of callee saved registers
so that we don't need to save/restore registers on stack
2. Remove second redundant mul instruction by re-arranging
instructions
Overall, we reduce 9 instructions in _hartid_to_scratch()
implementation.
Signed-off-by: Anup Patel <anup.patel@wdc.com>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'Makefile')
0 files changed, 0 insertions, 0 deletions