Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
15 years ago

Quartus II bug and fix for dynamic frequency scaling multicore CPUs

At least in the UNIX versions of Quartus II 10.1, whenever you start any tool it sources quartus/adm/qenv.sh to setup a sane environment for the tool. In that script, there is a check for the CPU frequency (it is unclear what Quartus does with that information, but nevermind).

On multicore systems it will extract all frequencies of all cores. The script then attempts to reduce the multiple returnvalues to a single value using "uniq", which works on multicore systems without per-core-independent frequency scaling. It fails rather annoyingly and (seemingly at first) randomly on multicore systems that use dynamic frequency scaling of the CPU-cores.

To solve the problem, apply the attached patch.

14 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    patch <'/home/evired/Downloads/patch.txt'

    patching file qenv.sh

    Hunk# 1 FAILED at 134.

    1 out of 1 hunk FAILED -- saving rejects to file qenv.sh.rej
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi BuGless,

    Sincerely thank you for this answer! It helps me solved the "export: 137: " problem, which have been around for months preventing the smooth execution of my batch compilation.

    My computer has an Intel dual core. The original "cat /proc/cpuinfo | grep "cpu MHz" | cut -c 12-18 | uniq" command sometimes return an answer with 2 lines, and this is the root cause of this problem. When I followed your patch to change it to "cat /proc/cpuinfo | grep "cpu MHz" | cut -c 12-18 | head -1", it always return a 1 line answer.

    I checked all the Quartus versions installed on my machine and I found that all the versions from 8.0sp1 to 10.1sp1 has this problem. A good thing to notice is that in version 11.0, this problematic line is removed.

    Obviously, some one from Altera has noticed this thread and took action. Hopefully it will not reemerge in the future versions.

    Thank you again!
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Glad to see it helps; that's the reason I traced and posted it. I'm also glad that you can confirm that they fixed it from 11.0 onward (just like aludwin said, earlier in this thread); I didn't have time to check/verify that myself yet.