1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 20:12:56 +02:00
Commit Graph

87 Commits

Author SHA1 Message Date
Sanjoy Das
7fe777fc31 Fix LLVM's handling and detection of skylake and cannonlake CPUs
Summary:
 - Rename `"skylake"` == SkylakeServerProc to `"skylake-avx512"`
 - Change `"skylake"` to denote SkylakeClientProc
 - Fix the detection of cpu family 6 and model 94 to be
   SkylakeClientProc instead of SkylakeServerProc
 - Remove the `"cnl"` for CannonLake

Reviewers: craig.topper, delena

Subscribers: zansari, echristo, qcolombet, RKSimon, spatel, DavidKreitzer, mcrosier, llvm-commits

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

llvm-svn: 261482
2016-02-21 17:12:03 +00:00
Elena Demikhovsky
832e2d5858 Added Skylake client to X86 targets and features
Changes in X86.td:

I set features of Intel processors in incremental form: IVB = SNB + X HSW = IVB + X ..
I added Skylake client processor and defined it's features
FeatureADX was missing on KNL
Added some new features to appropriate processors SMAP, IFMA, PREFETCHWT1, VMFUNC and others

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

llvm-svn: 258659
2016-01-24 10:41:28 +00:00
Michael Zuckerman
b0cb95e40b [AVX512] adding AVXVBMI feature flag
Fixing wrong typo (avx515) → (avx512) 
Review over the shoulder by asaf . 

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

llvm-svn: 258041
2016-01-18 11:12:47 +00:00
Michael Zuckerman
65f549e895 [AVX512] adding AVXVBMI feature flag
The feature flag is for VPERMB,VPERMI2B,VPERMT2B and VPMULTISHIFTQB instructions. 
More about the instruction can be found in:
hattps://software.intel.com/sites/default/files/managed/07/b7/319433-023.pdf

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

llvm-svn: 258012
2016-01-17 13:42:12 +00:00
Asaf Badouh
2b8c4d5c98 [x86] adding PKU feature flag
the feature flag is essential for RDPKRU and WRPKRU instruction 
more about the instruction can be found in the SDM rev 56, vol 2 from http://www.intel.com/sdm

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

llvm-svn: 255644
2015-12-15 13:35:29 +00:00
Craig Topper
b4211ec488 [X86] Update CPU detection to only enable XSAVE features if the OS has enabled them and the saving of YMM state. This seems to be consistent with gcc behavior.
llvm-svn: 250269
2015-10-14 05:37:42 +00:00
Amjad Aboud
7b91f508e9 [X86] Add XSAVE intrinsic family
Add intrinsics for the
  XSAVE instructions (XSAVE/XSAVE64/XRSTOR/XRSTOR64)
  XSAVEOPT instructions (XSAVEOPT/XSAVEOPT64)
  XSAVEC instructions (XSAVEC/XSAVEC64)
  XSAVES instructions (XSAVES/XSAVES64/XRSTORS/XRSTORS64)

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

llvm-svn: 250029
2015-10-12 11:47:46 +00:00
Chandler Carruth
c484a28f0a [ADT] Switch a bunch of places in LLVM that were doing single-character
splits to actually use the single character split routine which does
less work, and in a debug build is *substantially* faster.

llvm-svn: 247245
2015-09-10 06:12:31 +00:00
Craig Topper
5033eede06 Add model numbers for Skylake CPUs and an additional Broadwell model.
llvm-svn: 244385
2015-08-08 01:29:15 +00:00
Craig Topper
b81b70117f Add Intel family 6 model 93 as Silvermont.
llvm-svn: 244384
2015-08-08 01:16:05 +00:00
Craig Topper
ff53ab3a44 Add Intel family 6 model 90 as Silvermont. Fixes PR24392.
llvm-svn: 244352
2015-08-07 20:09:42 +00:00
Ulrich Weigand
05f3cb9f0c [SystemZ] Add z13 vector facility and MC support
This patch adds support for the z13 processor type and its vector facility,
and adds MC support for all new instructions provided by that facilily.

Apart from defining the new instructions, the main changes are:

- Adding VR128, VR64 and VR32 register classes.
- Making FP64 a subclass of VR64 and FP32 a subclass of VR32.
- Adding a D(V,B) addressing mode for scatter/gather operations
- Adding 1-, 2-, and 3-bit immediate operands for some 4-bit fields.
  Until now all immediate operands have been the same width as the
  underlying field (hence the assert->return change in decode[SU]ImmOperand).

In addition, sys::getHostCPUName is extended to detect running natively
on a z13 machine.

Based on a patch by Richard Sandiford.

llvm-svn: 236520
2015-05-05 19:23:40 +00:00
Craig Topper
f737774cb9 [X86] Stop changing result of getHostCPUName based on whether the processor supports AVX. getHostCPUFeatures should be used instead to determine whether to support AVX.
llvm-svn: 233674
2015-03-31 06:18:31 +00:00
Craig Topper
5f518e7132 [X86] Be more robust against unknown Intel family 6 models. Use feature flags to guess what it might be.
llvm-svn: 233671
2015-03-31 05:42:45 +00:00
Craig Topper
951df3a23a [X86] In getHostCPUFeatures, disable xop, f16c, fma, and fma4 if OS does not support saving ymm state.
llvm-svn: 233518
2015-03-30 06:31:14 +00:00
Craig Topper
8b36d1521f [X86] Use the more specific CPU names like 'nehalem', 'westmere', 'haswell', etc. Split Nehalem and Westmere CPUs.
llvm-svn: 233516
2015-03-30 06:31:09 +00:00
Craig Topper
dcf2d301c5 [X86] Move family 6 model 21 to 'pentium-m'. Near as I can tell this is a Dothan based SOC.
llvm-svn: 233515
2015-03-30 06:31:06 +00:00
Craig Topper
3192ada833 [X86] Family 6 model 29 is a Penryn based processor not a Nehalem based processor.
llvm-svn: 233514
2015-03-30 06:31:03 +00:00
Craig Topper
a6a2987b4d Fix a variable name in MSVC specific part of rr233487.
llvm-svn: 233488
2015-03-29 01:07:57 +00:00
Craig Topper
7aa2a33338 [X86] Implement getHostCPUFeatures for X86.
Plan to use this as part of CPU 'native' support so we can stop picking a different CPU name if CPU doesn't support AVX or AVX2.

llvm-svn: 233487
2015-03-29 01:00:23 +00:00
Craig Topper
21ffa88465 Fix typo 'AVX too' instead of 'AVX2'
llvm-svn: 232929
2015-03-23 04:17:11 +00:00
Craig Topper
ad12604e08 [X86] Add one stepping of Broadwell to the CPU name autodetection for march=native.
llvm-svn: 232927
2015-03-23 00:15:06 +00:00
Aaron Ballman
39606a007b We require MSVC 1800 as our minimum, so these checks can safely go away; NFC.
llvm-svn: 229415
2015-02-16 18:23:00 +00:00
Rafael Espindola
598eacab05 Remove a debugging assert.
Sorry for the noise, I have no idea how it survived to the final version.

llvm-svn: 224414
2014-12-17 03:38:04 +00:00
Rafael Espindola
d22f1dcf1a Fix the windows build.
llvm-svn: 224412
2014-12-17 02:42:20 +00:00
Rafael Espindola
28785d1703 Refactor and simplify the code reading /proc/cpuinfo. NFC.
llvm-svn: 224410
2014-12-17 02:32:44 +00:00
David Blaikie
7499cbae4c Remove StringMap::GetOrCreateValue in favor of StringMap::insert
Having two ways to do this doesn't seem terribly helpful and
consistently using the insert version (which we already has) seems like
it'll make the code easier to understand to anyone working with standard
data structures. (I also updated many references to the Entry's
key and value to use first() and second instead of getKey{Data,Length,}
and get/setValue - for similar consistency)

Also removes the GetOrCreateValue functions so there's less surface area
to StringMap to fix/improve/change/accommodate move semantics, etc.

llvm-svn: 222319
2014-11-19 05:49:42 +00:00
Will Schmidt
f6e2b6e4f5 Add support for ppc64/power8 as a host
llvm-svn: 211781
2014-06-26 13:37:03 +00:00
Hans Wennborg
7e14613d1d Fix .cpp files claiming to be header files
llvm-svn: 211334
2014-06-20 01:36:00 +00:00
Alp Toker
e8634eb077 Fix typos
llvm-svn: 209982
2014-05-31 21:26:28 +00:00
Bradley Smith
ff8ddaa911 Fixup sys::getHostCPUFeatures crypto names so it doesn't clash with kernel headers
llvm-svn: 209506
2014-05-23 10:14:13 +00:00
Bradley Smith
71322920b1 Extend sys::getHostCPUFeatures to work on AArch64 platforms
llvm-svn: 209420
2014-05-22 11:44:34 +00:00
Kaelyn Takata
5b23e5bb46 Select bdver2 instead of bdver1 if TBM support is present on models < 0x10.
Tested that the right -target-cpu is set in the clang -cc1 command line
when running "clang -march=native -E -v - </dev/null" on both an FX-8150
and an FX-8350. Both are family 15h; the FX-8150 (Bulldozer processor)
reports a model number of 1, and the FX-8350 (Piledriver processor)
reports a model number of 2.

llvm-svn: 207973
2014-05-05 16:32:10 +00:00
Benjamin Kramer
b0e4e7faba Add a description for AMD's bdver4 (aka Excavator).
This is just bdver3 + AVX2 + BMI2.

llvm-svn: 207847
2014-05-02 15:47:07 +00:00
Chandler Carruth
5038051a3d [Modules] Followup to r206822 to add a DEBUG_TYPE which is used on ARM
and PPC, but not x86.

llvm-svn: 206830
2014-04-21 23:58:10 +00:00
Kai Nacke
5274711425 Add support for krait cpu in llvm::sys::getHostCPUName()
Recently, support for krait cpu was added. This commit extends getHostCPUName()
to return krait as cpu for the APQ8064 (a Krait 300).

llvm-svn: 197792
2013-12-20 09:24:13 +00:00
Rafael Espindola
ada0b7030f Fix Typo.
llvm-svn: 197168
2013-12-12 16:17:40 +00:00
Rafael Espindola
f9ac791f38 Convert the other getHostByName implementations to StringRef.
llvm-svn: 197166
2013-12-12 16:10:48 +00:00
Rafael Espindola
8aebcbac61 Return a StringRef from getHostCPUName.
llvm-svn: 197158
2013-12-12 15:45:32 +00:00
Benjamin Kramer
9f1338e49d Make helper function static.
llvm-svn: 195650
2013-11-25 15:40:24 +00:00
Tim Northover
1b70928c82 X86: enable AVX2 under Haswell native compilation
Patch by Adam Strzelecki

llvm-svn: 195632
2013-11-25 09:52:59 +00:00
Benjamin Kramer
2d870f327a X86: Add a description for AMD bdver3 aka Steamroller.
This is just bdver2 + FSGSBase.

llvm-svn: 193984
2013-11-04 10:29:20 +00:00
Richard Sandiford
ae9a008dd7 [SystemZ] Automatically detect zEC12 and z196 hosts
As on other hosts, the CPU identification instruction is priveleged,
so we need to look through /proc/cpuinfo.  I copied the PowerPC way of
handling "generic".

Several tests were implicitly assuming z10 and so failed on z196.

llvm-svn: 193742
2013-10-31 12:14:17 +00:00
Preston Gurd
0411803c14 Adds support for Atom Silvermont (SLM) - -march=slm
Implements Instruction scheduler latencies for Silvermont,
using latencies from the Intel Silvermont Optimization Guide.

Auto detects SLM.

Turns on post RA scheduler when generating code for SLM.

llvm-svn: 190717
2013-09-13 19:23:28 +00:00
Benjamin Kramer
163da340ac X86: Add a description of the Intel Atom Silvermont CPU.
Currently this is just the atom model with SSE4.2 enabled.

llvm-svn: 189669
2013-08-30 14:05:32 +00:00
Reid Kleckner
b82543f2f3 Actually, use GNU inline asm for cpuid with clang
Clang doesn't support the MSVC __cpuid intrinsic yet, and fixing that is
blocked on some fairly complicated issues.

llvm-svn: 188584
2013-08-16 22:42:42 +00:00
Reid Kleckner
fbab94162c Use the MSVC __cpuid intrinsic instead of inline asm
This works around PR16830 in LLVM when self-hosting clang on Windows.

llvm-svn: 188397
2013-08-14 18:21:51 +00:00
Benjamin Kramer
9fe2707840 Some Intel Penryn CPUs come with SSE4 disabled. Detect them as core 2.
PR16721.

llvm-svn: 187350
2013-07-29 11:02:08 +00:00
Duncan Sands
ab07390e4a Ensure sys::getProcessTriple always uses a normalized triple. Patch by
Thomas B. Jablin, from PR16636.

llvm-svn: 186501
2013-07-17 11:01:05 +00:00
Tobias Grosser
30e2ef9685 Make host ARM CPU feature detection independent of the vendor
For ARM on linux we use /proc/cpuinfo to detect the host CPU's features.
Linux derives these values without ever looking at the vendor of the
specific CPU implementation. Hence, it adds little value, if we parse
the output of /proc/cpuinfo only for certain vendors.

This patch enables us to derive the correct feature flags e.g. for Qualcomm
CPUs.

llvm-svn: 183790
2013-06-11 21:45:01 +00:00