Mercurial > projects > ldc
comparison gen/abi-x86-64.cpp @ 1260:3d6a908a34e9
Add `#include "gen/llvm-version.h"` to files that use the macro it defines...
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Fri, 24 Apr 2009 16:47:42 +0200 |
parents | 152bd2c804d0 |
children | 6f4154b318ef |
comparison
equal
deleted
inserted
replaced
1259:dda95755f63d | 1260:3d6a908a34e9 |
---|---|
41 #include "gen/logger.h" | 41 #include "gen/logger.h" |
42 #include "gen/dvalue.h" | 42 #include "gen/dvalue.h" |
43 #include "gen/llvmhelpers.h" | 43 #include "gen/llvmhelpers.h" |
44 #include "gen/abi.h" | 44 #include "gen/abi.h" |
45 #include "gen/abi-x86-64.h" | 45 #include "gen/abi-x86-64.h" |
46 //#include "gen/llvm-version.h" // only use is commented out. | |
46 #include "ir/irfunction.h" | 47 #include "ir/irfunction.h" |
47 | 48 |
48 #include <cassert> | 49 #include <cassert> |
49 #include <map> | 50 #include <map> |
50 #include <string> | 51 #include <string> |
399 // calling convention. | 400 // calling convention. |
400 bool retStructInRegs(TypeStruct* st) { | 401 bool retStructInRegs(TypeStruct* st) { |
401 // 'fastcc' allows returns in up to two registers of each kind: | 402 // 'fastcc' allows returns in up to two registers of each kind: |
402 DRegCount state(2, 2, 2); | 403 DRegCount state(2, 2, 2); |
403 #if 1 //LLVM_REV < 67588 | 404 #if 1 //LLVM_REV < 67588 |
405 // (If uncommenting the LLVM_REV line above, also uncomment llvm-version #include | |
406 | |
404 // LLVM before trunk r67588 doesn't allow a second int to be an i1 or | 407 // LLVM before trunk r67588 doesn't allow a second int to be an i1 or |
405 // i8. (See <http://llvm.org/PR3861>) | 408 // i8. (See <http://llvm.org/PR3861>) |
406 // Rather than complicating shouldPassStructInRegs(), just disallow | 409 // Rather than complicating shouldPassStructInRegs(), just disallow |
407 // second integers for now. | 410 // second integers for now. |
408 // FIXME: Disabling this for older LLVM only makes the abi dependent on | 411 // FIXME: Disabling this for older LLVM only makes the abi dependent on |