This is an archive of the discontinued LLVM Phabricator instance.

[X86] Add XSAVE intrinsics (Clang part)
ClosedPublic

Authored by aaboud on Sep 21 2015, 5:45 AM.

Details

Summary

Add intrinsics for the XSAVE instructions:
XSAVE, XSAVE64
XRSTOR, XRSTOR64
XSAVEOPT, XSAVEOPT64
XRSTORS, XRSTORS64
XSAVEC, XSAVEC64
XSAVES, XSAVES64

These were previously declared in Intrin.h for MSVC compatibility, but now
that we have them implemented, these declarations can be removed.

Diff Detail

Repository
rL LLVM

Event Timeline

aaboud updated this revision to Diff 35235.Sep 21 2015, 5:45 AM
aaboud retitled this revision from to [X86] Add XSAVE intrinsics (Clang part).
aaboud updated this object.
aaboud added reviewers: mkuper, delena, craig.topper.
aaboud set the repository for this revision to rL LLVM.
aaboud added a subscriber: cfe-commits.
delena edited edge metadata.Oct 11 2015, 11:32 PM

Do you need to add some tests for clang?

Do you need to add some tests for clang?

I thought I did (see "builtins-x86.c").
This is how other intrinsic instructions are tested by clang, am I missing something?

aaboud updated this revision to Diff 37108.Oct 12 2015, 7:18 AM
aaboud edited edge metadata.

Added two LIT tests to check the xsave intrinsic instructions.

You should add the "xsave" features to all appropriate CPUs. It can be done in a separate patch.
LGTM.

This revision was automatically updated to reflect the committed changes.