pytorch / cpuinfo

CPU INFOrmation library (x86/x86-64/ARM/ARM64, Linux/Windows/Android/macOS/iOS)
BSD 2-Clause "Simplified" License
996 stars 314 forks source link

Implementing Cpuinfo for Power Architecture #234

Closed mikejuliet13 closed 3 months ago

mikejuliet13 commented 6 months ago

This pull request implements support for the cpuinfo library on the Power architecture. The cpuinfo library provides CPU information and features detection, and this implementation extends its capabilities to work seamlessly on Power-based systems. Changes Included: Added support for detecting Power architecture in cpuinfo Implemented Power-specific CPU feature detection

Testing: I have tested this implementation on Power systems running it on Trout, Laurel (Power9 arch.) and Ltcden2-lp1 (Power10 arch.) to ensure compatibility and correctness. The tests cover feature detection and library functionality specific to Power architecture.

Purpose: The purpose of this pull request is to enhance the cpuinfo library by adding support for Power architecture, enabling users of Power-based systems to utilise cpuinfo for CPU information retrieval and feature detection.

cc @malfet @fbarchard @jgong5 @mingfeima @XiaobingSuper @ashokei @jingxu10 @prashanthswami @Maratyszcza

facebook-github-bot commented 6 months ago

Hi @mikejuliet13!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

mikejuliet13 commented 5 months ago

Hi @mingfeima can you please look into this patch and assign a reviewer I work at IBM, we use system which run on power architecture, so this patch will help us use cpuinfo on our systems

malfet commented 5 months ago

@mikejuliet13 Can you add a CI for it? Using qemu, similarly to how it's done for riscv?

mikejuliet13 commented 5 months ago

detailed test plan on how this change was validated.

We tested all the changes on Power 8, Power 9 and Power 10 machine and x86 machine, all the 132 testcases have passed in every machine. We have also run make check command to test the custom testcase added to test the availability of certain power features Would you please accept the change and merge it for now We’ll be working on adding a CI for power platform with qemu soon after this, as it may take some time

mikejuliet13 commented 4 months ago

Hi @malfet I have added power-specific testcases in test/name/power-features.cc, and I have tested it out on several machines and it works fine on those power machines Kindly review it and approve the merge request as soon as possible We need this library in our tensorflow project also

mikejuliet13 commented 3 months ago

Hi @malfet we are awaiting your review I think I have addressed all the comments. The CI using qemu, that supports power platform, we will take it up internally, but all the testings we have done because of new changes have run successfully on all the machines. Kindly review it and approve the merge request as soon as possible

mikejuliet13 commented 3 months ago

I am closing this PR We will raise a new PR