View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0000401 | JEDI Code Library | JclSysInfo | public | 2002-10-31 09:22 | 2005-02-16 01:34 |
| Reporter | anonymous | Assigned To | Robert Rossmair | ||
| Priority | normal | Severity | major | Reproducibility | sometimes |
| Status | closed | Resolution | fixed | ||
| Product Version | |||||
| Target Version | Fixed in Version | ||||
| Summary | 0000401: ERangeError in GetCPUSpeed | ||||
| Description | Of course, this only happens when range checking is enabled. The JclSysInfo unit is not explicitly used by my project, but implicitly used through a chain of Jcl units. My project is a Delphi DLL loaded by a VC++ host application. The exception never happens on my machine (Dual 1.5GHz P4 Xeon), but happens all the time on my coworkers machine (Dual 2.0GHz P4 Xeon). The biggest part of the problem is that the exception occurs during unit initialization, where exception handling mechanisms are sparse if present at all. Thus, the exception propagates back to the host application. Perhaps this is a symptom of a larger issue--exception handling needs to be improved in all initialization sections of Jcl units. | ||||
| Additional Information | Here is a stack trace as generated from the TJclStackInfoList using TD32 debug info. The JCL version in use is 1.21. I checked, and version 1.22 doesn't change the GetCPUSpeed function in any way. The line that is flagged as raising the exception is: Freq := Round(Cycles / Ticks); ERangeError: Range check error[01730221] PeekPeerMapExceptTrace.ExceptNotify (Line 21, "PeekPeerMapExceptTrace.pas")[0172BD6B] JclHookExcept.TNotifierItem.DoNotify (Line 197, "JclHookExcept.pas")[0172BE31] JclHookExcept.DoExceptNotify (Line 225, "JclHookExcept.pas")[0172BECC] JclHookExcept.HookedRaiseException (Line 249, "JclHookExcept.pas")[01726BC4] JclSysInfo.GetCPUSpeed (Line 2293, "JclSysInfo.pas")[016F283E] System.ErrorAt (Line 2944, "system.pas")[017268CC] JclSysInfo.GetCpuInfo (Line 2195, "JclSysInfo.pas")[016F41B3] System.@StartLib (Line 10710, "system.pas")First-chance exception at 0x77e73887 in Peek.exe: 0x0EEDFADE: 0xeedfade. | ||||
| Tags | No tags attached. | ||||
| Fixed in GIT commit | |||||
| Fixed in SVN revision | |||||
| IDE version | |||||
| has duplicate | 0000801 | closed | Robert Rossmair | JEDI Code Library | JclSysInfo.GetCPUSpeed - division by zero |
| has duplicate | 0000981 | closed | Robert Rossmair | JEDI Code Library | Division by zero in JclSysInfo |
| has duplicate | 0001007 | closed | Robert Rossmair | JEDI Code Library | GetCPUSpeed() crashes on Hyperthreading CPUs |
| has duplicate | 0001020 | closed | Robert Rossmair | JEDI VCL | GetCPUInfo results in Floating Point Division by Zero (Runtime Error 216 ) |
|
|
This note is from the original bug submitter. Correction: my coworkers machine is a Dual 2.2GHz P4 Xeon. The GetCpuInfo procedure is called from JclGraphUtils.SetupFunctions, which is invoked from its initialization section. edited on: 10-31 11:59 |
|
2003-06-28 12:43
|
JclSysInfo.zip (20,286 bytes) |
|
|
Fixed as of 2003-05-17, see attached file. |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2005-02-16 01:34 | Robert Rossmair | Status | resolved => closed |