Skip to content
Commit cd28bce8 authored by Davide Italiano's avatar Davide Italiano
Browse files

[ABI] Rewrite RegisterIsCalleeSaved.

The goal of this patch is twofold:
First, it removes a wrong comment (at least, not correctly describing
what the function does).
Then, it rewrites the function to use a StringSwitch where the
registers are enumerated explicitly instead of being computed
programmatically. Other than being much shorter, it's much easier to
read (and given the ABI won't change anytime soon, I don't think
there's need to generalize).

While here, I added an assert that the register name is always empty,
as the previous implementation of the function assumed so.

Differential Revision:  https://reviews.llvm.org/D37420

llvm-svn: 312501
parent 9e68b734
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment