mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-10-17 16:27:26 +02:00
Remove unused, empty Ir type.
The codegen parameter was changed to IRState instead of removing it to set the stage for an eventual eradication of the gIR global.
This commit is contained in:
+8
-10
@@ -10,14 +10,10 @@
|
||||
#include <assert.h>
|
||||
|
||||
#include "target.h"
|
||||
#include "gen/irstate.h"
|
||||
#include "mars.h"
|
||||
#include "mtype.h"
|
||||
|
||||
unsigned GetTypeAlignment(Type* t);
|
||||
unsigned GetPointerSize();
|
||||
unsigned GetTypeStoreSize(Type* t);
|
||||
unsigned GetTypeAllocSize(Type* t);
|
||||
|
||||
int Target::ptrsize;
|
||||
int Target::realsize;
|
||||
int Target::realpad;
|
||||
@@ -25,10 +21,12 @@ int Target::realalignsize;
|
||||
|
||||
void Target::init()
|
||||
{
|
||||
ptrsize = GetPointerSize();
|
||||
realsize = GetTypeAllocSize(Type::basic[Tfloat80]);
|
||||
realpad = realsize - GetTypeStoreSize(Type::basic[Tfloat80]);
|
||||
realalignsize = GetTypeAlignment(Type::basic[Tfloat80]);
|
||||
ptrsize = gDataLayout->getPointerSize(ADDRESS_SPACE);
|
||||
|
||||
llvm::Type* real = DtoType(Type::basic[Tfloat80]);
|
||||
realsize = gDataLayout->getTypeAllocSize(real);
|
||||
realpad = realsize - gDataLayout->getTypeStoreSize(real);
|
||||
realalignsize = gDataLayout->getABITypeAlignment(real);
|
||||
}
|
||||
|
||||
/******************************
|
||||
@@ -39,7 +37,7 @@ unsigned Target::alignsize (Type* type)
|
||||
{
|
||||
assert (type->isTypeBasic());
|
||||
if (type->ty == Tvoid) return 1;
|
||||
return GetTypeAlignment(type);
|
||||
return gDataLayout->getABITypeAlignment(DtoType(type));
|
||||
}
|
||||
|
||||
/******************************
|
||||
|
||||
Reference in New Issue
Block a user