diff options
author | Eric Christopher <echristo@gmail.com> | 2014-02-20 02:40:45 +0000 |
---|---|---|
committer | Eric Christopher <echristo@gmail.com> | 2014-02-20 02:40:45 +0000 |
commit | eed3d708ee72d9b580fd7614e36924bfeab7e988 (patch) | |
tree | f98c9d5b166ecfe90e565791c29b0eb745600196 /lib/CodeGen/AsmPrinter/DIE.h | |
parent | 0af815c0dc8f6996962fe4f56e5f2c716e40bac5 (diff) | |
download | llvm-eed3d708ee72d9b580fd7614e36924bfeab7e988.tar.gz llvm-eed3d708ee72d9b580fd7614e36924bfeab7e988.tar.bz2 llvm-eed3d708ee72d9b580fd7614e36924bfeab7e988.tar.xz |
Make DIELoc/DIEBlock's ComputeSize method const. Add a setSize
method to actually set it in the class to avoid computing it
multiple times.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201751 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter/DIE.h')
-rw-r--r-- | lib/CodeGen/AsmPrinter/DIE.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/CodeGen/AsmPrinter/DIE.h b/lib/CodeGen/AsmPrinter/DIE.h index a35229da91..d4f3154d15 100644 --- a/lib/CodeGen/AsmPrinter/DIE.h +++ b/lib/CodeGen/AsmPrinter/DIE.h @@ -451,7 +451,11 @@ namespace llvm { /// ComputeSize - Calculate the size of the location expression. /// - unsigned ComputeSize(AsmPrinter *AP); + unsigned ComputeSize(AsmPrinter *AP) const; + + /// setSize - Set the size of the location entry. + /// + void setSize(unsigned Sz) { Size = Sz; } /// BestForm - Choose the best form for data. /// @@ -490,7 +494,11 @@ namespace llvm { /// ComputeSize - Calculate the size of the location expression. /// - unsigned ComputeSize(AsmPrinter *AP); + unsigned ComputeSize(AsmPrinter *AP) const; + + /// setSize - Set the size of the block. + /// + void setSize(unsigned Sz) { Size = Sz; } /// BestForm - Choose the best form for data. /// |