Mercurial > projects > ldc
view gen/structs.h @ 971:985104c0f1db
Fix the problems exposed by the callingconv1.d test case.
The first was that unless otherwise specified, inputs are assumed to be in
registers even if they specify a "matching output" that's in memory.
While testing that fix, I also ran into a bug causing the generated "matching
output" for any input was always the first one instead of the correct one.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Tue, 17 Feb 2009 00:08:20 +0100 |
parents | af7a6faf9406 |
children | 3cf0066e6faf |
line wrap: on
line source
#ifndef LLVMD_GEN_STRUCTS_H #define LLVMD_GEN_STRUCTS_H struct StructInitializer; LLConstant* DtoConstStructInitializer(StructInitializer* si); std::vector<llvm::Value*> DtoStructLiteralValues(const StructDeclaration* sd, const std::vector<llvm::Value*>& inits); /** * Resolves the llvm type for a struct */ void DtoResolveStruct(StructDeclaration* sd); /** * Provides the llvm declaration for a struct */ void DtoDeclareStruct(StructDeclaration* sd); /** * Constructs the constant default initializer a struct */ void DtoConstInitStruct(StructDeclaration* sd); /** * Provides the llvm definition for a struct */ void DtoDefineStruct(StructDeclaration* sd); /** * Returns a boolean=true if the two structs are equal */ LLValue* DtoStructEquals(TOK op, DValue* lhs, DValue* rhs); // index a struct one level LLValue* DtoIndexStruct(LLValue* src, StructDeclaration* sd, VarDeclaration* vd); #endif