Tux / System-Info

System::Info - basic information about the system
1 stars 6 forks source link

Apple M1 error on cpu speed #7

Closed mesopelagique closed 3 years ago

mesopelagique commented 3 years ago

Hi,

I have this issue on Mac M1

Use of uninitialized value $system_profiler{"cpu speed"} in substitution (s///) at .../lib/perl5/System/Info/Darwin.pm line 105.
Use of uninitialized value in concatenation (.) or string at .../lib/perl5/System/Info/Darwin.pm line 49.

I see that module use /usr/sbin/system_profiler -detailLevel mini SPHardwareDataType SPSoftwareDataType

With a M1 there is no "Processor speed" in output

Hardware:

    Hardware Overview:

      Model Name: Mac mini
      Model Identifier: Macmini9,1
      Chip: Apple M1
      Total Number of Cores: 8 (4 performance and 4 efficiency)
      Memory: 16 GB
      System Firmware Version: 6723.120.36
      OS Loader Version: 6723.120.36

Software:

    System Software Overview:

      System Version: macOS 11.4 (20F71)
      Kernel Version: Darwin 20.5.0
      Time since boot: 6 days 20 minutes

if launched with Rosetta (force intel emulation), because perl has been launched in rosetta too, there is no problem

Hardware:

    Hardware Overview:

      Model Name: Mac mini
      Model Identifier: Macmini9,1
      Processor Name: Unknown
      Processor Speed: 2,4 GHz
      Number of Processors: 1
      Total Number of Cores: 8
      L2 Cache (per Core): 4 MB
      Memory: 16 GB

Software:

    System Software Overview:

      System Version: macOS 11.4 (20F71)
      Kernel Version: Darwin 20.5.0
      Time since boot: 6 days 14 minutes
Tux commented 3 years ago

Thanks for this feedback. Patched and pushed. Will be in release 0.061.

briandfoy commented 3 years ago

The current sources work for me on the same system in the initial report. Maybe it's time for a push of 0.061 :)

Tux commented 3 years ago

Done