Revert 209903 and 210040.

The messages were

 "PR19753: Optimize comparisons with "ashr exact" of a constanst."
 "Added support to optimize comparisons with "lshr exact" of a constant."

They were not correctly handling signed/unsigned operation differences,
causing pr19958.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210393 91177308-0d34-0410-b5e6-96231b3b80d8
[OCaml] Introduce an llmdkind abstract type.

Patch by Gabriel Radanne.

While this commit technically breaks API, no code should have supplied
the integer IDs directly, and thus no code should break.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210395 91177308-0d34-0410-b5e6-96231b3b80d8
[OCaml] Commit missing parts of r210395

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210396 91177308-0d34-0410-b5e6-96231b3b80d8
tools: add a high level explanation for WoA EH data

Add a brief explanation of the data section layout for the unwind data that the
Windows on ARM EH models.  This is simply to provide a rough idea of the layout
of the code involved in the decoding of the unwinding.  Details on the involved
data structures are available in the associated support header.  The bulk of it
is related to printing out the byte-code to help validate generation of WoA EH.

No functional change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210397 91177308-0d34-0410-b5e6-96231b3b80d8
ARM: correct assertion for long-calls on WoA

COFF/PE, so the relocation model is never static.  Loosen the assertion
accordingly.  The relocation can still be emitted properly, as it will be
converted to an IMAGE_REL_ARM_ADDR32 which will be resolved by the loader
taking the base relocation into account.  This is necessary to permit the
emission of long calls which can be controlled via the -mlong-calls option in
the driver.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210399 91177308-0d34-0410-b5e6-96231b3b80d8
Build fix: remove initializeJumpInstrTablesPass() call from LTO

This was incurring an unsatisfied dependency on CodeGen from LTO breaking
shared builds:

Undefined symbols for architecture x86_64:
  "llvm::initializeJumpInstrTablesPass(llvm::PassRegistry&)", referenced from:
      llvm::LTOCodeGenerator::initializeLTOPasses() in LTOCodeGenerator.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Removed as a temporary measure pending feedback from the author.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210400 91177308-0d34-0410-b5e6-96231b3b80d8
Fix typos

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210401 91177308-0d34-0410-b5e6-96231b3b80d8
MC: whitespace, grouping for COFF section setup

Add some whitespace, combine two sequential conditionals into a single one.
Reformat some section definitions to maintain uniformity in the function.
NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210405 91177308-0d34-0410-b5e6-96231b3b80d8
MC: fix ctor/dtor section for windows-itanium

This adjusts the section setup for the windows-itanium environment.  This
environment does not report to be a known windows msvc environment, even though
it is (nearly) identical to the MSVC environment for C code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210406 91177308-0d34-0410-b5e6-96231b3b80d8
MC: make ELF .type handling more GNU AS compatible

GAS documents the .type directive as having an optional comma following the key
symbol name when using the STT_<TYPE_IN_UPPER_CASE> form.  However, it treats
the comma as optional in all cases.  This makes the IAS support both forms of
inputs.  Furthermore, the prefixed forms take either the upper case name or the
lower case alias.

The tests are split into two separate sets as the hash character serves as a
comment character on x86, which is tested in the second set by using arm-elf
which uses the at symbol as a comment character.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210407 91177308-0d34-0410-b5e6-96231b3b80d8
test: move some tests into ARM directory

Rather than requiring ARM support for the ELF tests (which is odd), move the
tests that require ARM into a subdirectory to use lit to disable them if the
support is not present.  Play this game to prevent disabling the ELF tests on
the Windows build bots as they have caught issues in the past with interactions
between various platforms.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210408 91177308-0d34-0410-b5e6-96231b3b80d8
test: add test case for SVN r210406

Add missing test case for constructor section selection.  Thanks David Blaikie!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210409 91177308-0d34-0410-b5e6-96231b3b80d8
include MipsGenFastISel.inc

Summary:
Included this file which is needed to enable tablegen generated functionality
for fast mips-isel

Test Plan:
This has no visible functionality by itself but just adding the include
file creates some issues so I have it as a separate patch.

Reviewers: dsanders

Reviewed By: dsanders

Differential Revision: http://reviews.llvm.org/D3812

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210410 91177308-0d34-0410-b5e6-96231b3b80d8
Fix build when no native target is enabled

The JITTests and MCJITTests unit test targets require a native arch with JIT
support, otherwise fail to link.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210411 91177308-0d34-0410-b5e6-96231b3b80d8
Re-enable ARM ELF tests

r210408 inadvertently disabled them when X86 is not selected.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210412 91177308-0d34-0410-b5e6-96231b3b80d8
start to clean up buildMI calls in mips fast-isel

Summary: Merge branch 'master' into 1758_6

Test Plan:
No functionality change. Run "make check" and run test-suite.
Because our servers are not yet running again I have not yet run test-suite.
I will further review myself before submission.

Reviewers: dsanders

Reviewed By: dsanders

Differential Revision: http://reviews.llvm.org/D3819

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210413 91177308-0d34-0410-b5e6-96231b3b80d8
Do materialize for floating point

Summary:
start to do simple constants

finish simplestore

add test case

format

Merge branch 'master' into 1756_8

Add basic functionality for assignment of ints. This creates a lot of core infrastructure in which to add, with little effort, quite a bit more to mips fast-isel

Merge branch 'master' into 1756_8

Add basic functionality for assignment of ints. This creates a lot of core infrastructure in which to add, with little effort, quite a bit more to mips fast-isel

in progress

finish integer materialize

test cases

test cases

in progress

Finish up fast-isel materialize for ints.

Finish materialize for ints

test cases

simplestorei.ll

Merge branch 'master' into 1756_8

fix fp constants for fast-isel

Merge branch '1758_1' of dmz-portal.mips.com:llvm into 1758_1

in progress

lastest for fp materialization

clean up

Merge branch 'master' into 1758_1

formatting

add test case

finish test case

Merge branch 'master' into 1758_2

Test Plan:
simplestore.ll

simplestore.ll

Reviewers: dsanders

Reviewed By: dsanders

Differential Revision: http://reviews.llvm.org/D3659

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210414 91177308-0d34-0410-b5e6-96231b3b80d8
MC: fix text section characteristics for WoA

link.exe requires that the text section has the IMAGE_SCN_MEM_16BIT flag set.
Otherwise, it will treat the function as ARM.  If this occurs, then jumps to the
function will fail, switching from thumb to ARM mode execution.

With this change, it is possible to link using the MSVC linker as well.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210415 91177308-0d34-0410-b5e6-96231b3b80d8
Make InlineAsmIdentifierInfo forward-declarable

This helps localize header inclusion in the frontend.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210417 91177308-0d34-0410-b5e6-96231b3b80d8
Remove redundant typedef from MCAsmParserSemaCallback

The last use has been removed in clang r210418.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210419 91177308-0d34-0410-b5e6-96231b3b80d8