hanchenye-llvm-project/llvm/lib
Daniel Sanders 059e4b158c [mips][fp64] Add an implicit def to MFHC1 claiming that it reads the lower 32-bits of 64-bit FPR
Summary:
This is a white lie to workaround a widespread bug in the -mfp64
implementation.

The problem is that none of the 32-bit fpu ops mention the fact that they
clobber the upper 32-bits of the 64-bit FPR. This allows MFHC1 to be
scheduled on the wrong side of most 32-bit FPU ops. Fixing that requires a
major overhaul of the FPU implementation which can't be done right now due to
time constraints.

MFHC1 is one of two affected instructions. These instructions are the only
FPU instructions that don't read or write the lower 32-bits. We therefore
pretend that it reads the bottom 32-bits to artificially create a dependency and
prevent the scheduler changing the behaviour of the code.
The other instruction is MTHC1 which will be fixed once I've have found a failing
test case for it. 

The testcase is test-suite/SingleSource/UnitTests/Vector/simple.c when
given TARGET_CFLAGS="-mips32r2 -mfp64 -mmsa".

Reviewers: jacksprat, matheusalmeida

Reviewed By: jacksprat

Differential Revision: http://llvm-reviews.chandlerc.com/D2966

llvm-svn: 203464
2014-03-10 15:01:57 +00:00
..
Analysis [TTI] There is actually no realistic way to pop TTI implementations off 2014-03-10 02:45:14 +00:00
AsmParser IR: Change inalloca's grammar a bit 2014-03-09 06:41:58 +00:00
Bitcode [C++11] Add range based accessors for the Use-Def chain of a Value. 2014-03-09 03:16:01 +00:00
CodeGen [C++11] Remove 'virtual' keyword from methods marked with 'override' keyword. 2014-03-10 05:29:18 +00:00
DebugInfo Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
ExecutionEngine Make createObjectImage and createObjectImageFromFile static methods on the 2014-03-08 18:45:12 +00:00
IR [PM] While I'm here, fix a few other clang-format issues. Pulls some 2014-03-10 02:12:14 +00:00
IRReader Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
LTO [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:51:20 +00:00
LineEditor [CMake] Use LINK_LIBS instead of target_link_libraries(). 2014-02-26 06:41:29 +00:00
Linker [Layering] Sink Linker.h into a Linker subdirectory to make it 2014-03-06 03:42:23 +00:00
MC MC: Appease the buildbots 2014-03-10 01:04:18 +00:00
Object Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
Option Avoid buffer copies when a Twine already is a StringRef. 2013-12-03 18:18:28 +00:00
Support [C++11] Remove 'virtual' keyword from methods marked with 'override' keyword. 2014-03-10 03:53:12 +00:00
TableGen Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
Target [mips][fp64] Add an implicit def to MFHC1 claiming that it reads the lower 32-bits of 64-bit FPR 2014-03-10 15:01:57 +00:00
Transforms SimplifyCFG: Simplify the weight scaling algorithm. 2014-03-09 14:42:55 +00:00
CMakeLists.txt Introduce line editor library. 2014-01-31 23:46:14 +00:00
LLVMBuild.txt Introduce line editor library. 2014-01-31 23:46:14 +00:00
Makefile Introduce line editor library. 2014-01-31 23:46:14 +00:00