aboutsummaryrefslogtreecommitdiff
path: root/lib/Bytecode
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-01-15 06:11:30 +0000
committerChris Lattner <sabre@nondot.org>2004-01-15 06:11:30 +0000
commitc8434e3d71105e2e908c7b07fc190a74c6b2ddf0 (patch)
treec0399f76fdc9518c3b24db03b20a0a1736e0edfa /lib/Bytecode
parentfebdf58538c2510ec1c24d3a856420792c53debe (diff)
Remove the optimization that depends on ENDIAN_LITTLE: it's not worth it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10870 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bytecode')
-rw-r--r--lib/Bytecode/Writer/WriterPrimitives.h8
1 files changed, 0 insertions, 8 deletions
diff --git a/lib/Bytecode/Writer/WriterPrimitives.h b/lib/Bytecode/Writer/WriterPrimitives.h
index e5079e8bb9..5bb0166518 100644
--- a/lib/Bytecode/Writer/WriterPrimitives.h
+++ b/lib/Bytecode/Writer/WriterPrimitives.h
@@ -27,13 +27,6 @@ namespace llvm {
//
static inline void output(unsigned i, std::deque<unsigned char> &Out,
int pos = -1) {
-#ifdef ENDIAN_LITTLE
- if (pos == -1)
- Out.insert(Out.end(), (unsigned char*)&i, (unsigned char*)&i+4);
- else
- // This cannot use block copy because deques are not guaranteed contiguous!
- std::copy((unsigned char*)&i, 4+(unsigned char*)&i, Out.begin()+pos);
-#else
if (pos == -1) { // Be endian clean, little endian is our friend
Out.push_back((unsigned char)i);
Out.push_back((unsigned char)(i >> 8));
@@ -45,7 +38,6 @@ static inline void output(unsigned i, std::deque<unsigned char> &Out,
Out[pos+2] = (unsigned char)(i >> 16);
Out[pos+3] = (unsigned char)(i >> 24);
}
-#endif
}
static inline void output(int i, std::deque<unsigned char> &Out) {