remove the source location arguments to various target query methods.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@47954 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Basic/TargetInfo.cpp b/Basic/TargetInfo.cpp
index 8701b38..1f0bece 100644
--- a/Basic/TargetInfo.cpp
+++ b/Basic/TargetInfo.cpp
@@ -28,22 +28,19 @@
// TargetInfoImpl.
void TargetInfo::getFloatInfo(uint64_t &Size, unsigned &Align,
- const llvm::fltSemantics *&Format,
- FullSourceLoc Loc) {
+ const llvm::fltSemantics *&Format) {
Align = 32; // FIXME: implement correctly.
Size = 32;
Format = &llvm::APFloat::IEEEsingle;
}
void TargetInfo::getDoubleInfo(uint64_t &Size, unsigned &Align,
- const llvm::fltSemantics *&Format,
- FullSourceLoc Loc) {
+ const llvm::fltSemantics *&Format) {
Size = 64; // FIXME: implement correctly.
Align = 32;
Format = &llvm::APFloat::IEEEdouble;
}
void TargetInfo::getLongDoubleInfo(uint64_t &Size, unsigned &Align,
- const llvm::fltSemantics *&Format,
- FullSourceLoc Loc) {
+ const llvm::fltSemantics *&Format) {
Size = Align = 64; // FIXME: implement correctly.
Format = &llvm::APFloat::IEEEdouble;
//Size = 80; Align = 32; // FIXME: implement correctly.
@@ -74,7 +71,7 @@
/// ComputeWCharWidth - Determine the width of the wchar_t type for the primary
/// target, diagnosing whether this is non-portable across the secondary
/// targets.
-void TargetInfo::ComputeWCharInfo(FullSourceLoc Loc) {
+void TargetInfo::ComputeWCharInfo() {
Target->getWCharInfo(WCharWidth, WCharAlign);
}
diff --git a/Basic/Targets.cpp b/Basic/Targets.cpp
index d170fbe..89125b4 100644
--- a/Basic/Targets.cpp
+++ b/Basic/Targets.cpp
@@ -722,50 +722,6 @@
} // end anonymous namespace.
-namespace {
-class LinuxTargetInfo : public DarwinTargetInfo {
-public:
- LinuxTargetInfo(const std::string& triple) : DarwinTargetInfo(triple) {
- // Note: I have no idea if this is right, just for testing.
- WCharWidth = 16;
- WCharAlign = 16;
- }
-
- virtual void getTargetDefines(std::vector<char> &Defines) const {
- // TODO: linux-specific stuff.
- getX86Defines(Defines, false);
- }
- virtual void getTargetBuiltins(const Builtin::Info *&Records,
- unsigned &NumRecords) const {
- X86::getBuiltins(Records, NumRecords);
- }
- virtual const char *getVAListDeclaration() const {
- return getI386VAListDeclaration();
- }
- virtual const char *getTargetPrefix() const {
- return X86::getTargetPrefix();
- }
- virtual void getGCCRegNames(const char * const *&Names,
- unsigned &NumNames) const {
- X86::getGCCRegNames(Names, NumNames);
- }
- virtual void getGCCRegAliases(const GCCRegAlias *&Aliases,
- unsigned &NumAliases) const {
- X86::getGCCRegAliases(Aliases, NumAliases);
- }
- virtual bool validateAsmConstraint(char c,
- TargetInfo::ConstraintInfo &info) const {
- return X86::validateAsmConstraint(c, info);
- }
- virtual std::string convertConstraint(const char Constraint) const {
- return X86::convertConstraint(Constraint);
- }
- virtual const char *getClobbers() const {
- return X86::getClobbers();
- }
-};
-} // end anonymous namespace.
-
//===----------------------------------------------------------------------===//
// Driver code
@@ -794,9 +750,6 @@
if (IsX86(T))
return new TargetInfo(new DarwinI386TargetInfo(T));
- if (T.find("bogusW16W16-") == 0) // For testing portability.
- return new TargetInfo(new LinuxTargetInfo(T));
-
return NULL;
}