[llvm-commits] [llvm] r47401 - in /llvm/trunk/lib: AsmParser/llvmAsmParser.y Bitcode/Writer/BitcodeWriter.cpp
Dale Johannesen
dalej at apple.com
Wed Feb 20 13:15:19 PST 2008
Author: johannes
Date: Wed Feb 20 15:15:19 2008
New Revision: 47401
URL: http://llvm.org/viewvc/llvm-project?rev=47401&view=rev
Log:
Support alignment within ParamAttrs in the I/O handling.
Modified:
llvm/trunk/lib/AsmParser/llvmAsmParser.y
llvm/trunk/lib/Bitcode/Writer/BitcodeWriter.cpp
Modified: llvm/trunk/lib/AsmParser/llvmAsmParser.y
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/AsmParser/llvmAsmParser.y?rev=47401&r1=47400&r2=47401&view=diff
==============================================================================
--- llvm/trunk/lib/AsmParser/llvmAsmParser.y (original)
+++ llvm/trunk/lib/AsmParser/llvmAsmParser.y Wed Feb 20 15:15:19 2008
@@ -1233,6 +1233,7 @@
| NOALIAS { $$ = ParamAttr::NoAlias; }
| BYVAL { $$ = ParamAttr::ByVal; }
| NEST { $$ = ParamAttr::Nest; }
+ | ALIGN EUINT64VAL { $$ = $2 << 16; }
;
OptParamAttrs : /* empty */ { $$ = ParamAttr::None; }
Modified: llvm/trunk/lib/Bitcode/Writer/BitcodeWriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Bitcode/Writer/BitcodeWriter.cpp?rev=47401&r1=47400&r2=47401&view=diff
==============================================================================
--- llvm/trunk/lib/Bitcode/Writer/BitcodeWriter.cpp (original)
+++ llvm/trunk/lib/Bitcode/Writer/BitcodeWriter.cpp Wed Feb 20 15:15:19 2008
@@ -119,7 +119,7 @@
const ParamAttrsList *A = Attrs[i];
for (unsigned op = 0, e = A->size(); op != e; ++op) {
Record.push_back(A->getParamIndex(op));
- Record.push_back((uint16_t)A->getParamAttrsAtIndex(op));
+ Record.push_back(A->getParamAttrsAtIndex(op));
}
Stream.EmitRecord(bitc::PARAMATTR_CODE_ENTRY, Record);
More information about the llvm-commits
mailing list