X86TargetInfo.cpp 1000 B

12345678910111213141516171819202122232425262728
  1. //===-- X86TargetInfo.cpp - X86 Target Implementation ---------------------===//
  2. //
  3. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  4. // See https://llvm.org/LICENSE.txt for license information.
  5. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  6. //
  7. //===----------------------------------------------------------------------===//
  8. #include "TargetInfo/X86TargetInfo.h"
  9. #include "llvm/MC/TargetRegistry.h"
  10. using namespace llvm;
  11. Target &llvm::getTheX86_32Target() {
  12. static Target TheX86_32Target;
  13. return TheX86_32Target;
  14. }
  15. Target &llvm::getTheX86_64Target() {
  16. static Target TheX86_64Target;
  17. return TheX86_64Target;
  18. }
  19. extern "C" LLVM_EXTERNAL_VISIBILITY void LLVMInitializeX86TargetInfo() {
  20. RegisterTarget<Triple::x86, /*HasJIT=*/true> X(
  21. getTheX86_32Target(), "x86", "32-bit X86: Pentium-Pro and above", "X86");
  22. RegisterTarget<Triple::x86_64, /*HasJIT=*/true> Y(
  23. getTheX86_64Target(), "x86-64", "64-bit X86: EM64T and AMD64", "X86");
  24. }