This is an archive of the discontinued LLVM Phabricator instance.

Add computeHostNumPhysicalCores() implementation for Darwin
ClosedPublic

Authored by mehdi_amini on Oct 19 2016, 2:58 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

mehdi_amini retitled this revision from to Add computeHostNumPhysicalCores() implementation for Darwin.
mehdi_amini updated this object.
mehdi_amini added a reviewer: tejohnson.
mehdi_amini added a subscriber: llvm-commits.
tejohnson added inline comments.Oct 19 2016, 3:07 PM
lib/Support/Host.cpp
1237 ↗(On Diff #75236)

Is this true only for x86?

mehdi_amini added inline comments.Oct 19 2016, 3:13 PM
lib/Support/Host.cpp
1237 ↗(On Diff #75236)

The syscall should work on every Apple Darwin platform, but I haven't a build of LLVM that runs on a device to validate it right now, I can ifdef on X86 as well for now.

Haven't tested other platform than x86_64 right now, add this as conditional compilation.

tejohnson accepted this revision.Oct 19 2016, 3:44 PM
tejohnson edited edge metadata.

LGTM Thanks!

This revision is now accepted and ready to land.Oct 19 2016, 3:44 PM
This revision was automatically updated to reflect the committed changes.