Skip to contentSkip to conversation

dosemu 1.1.x and 1.1.4.13 bug (?) on CPUs faster than 2.0GHz

DISCUSSION Maurilio Longo 4 participants 9 messages Mar 11, 2003 – Mar 13, 2003

lore
Share & tools
lore
#0 lore raw

Hi,

latest dosemu has problems (locks up here and there) if it is run on a 2.4GHz pentium IV and inside dosemu.conf I have

$_rdtsc(on)
$_cpuspeed(0)

I think this comes from the fact that on startup it gives me a negative cpu speed

Kernel CPU speed is -1894957296Hz

I'm running a protect mode dos clipper program. Same system on a 2.0GHz cpu works flawlessly and it works ok as soon as I set rdtsc to off.

Also, there are problems with locks if I don't run it thruogh NETX on a novell server and, instead, I run it on my "C:" disk (which is a directory on my linux). I'll try to be more precise on the coming days.

regards.

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia
#1 lore raw

Any comments?

Nobody stumbled on this issue?

curious :)

Maurilio.

Maurilio Longo ha scritto:

Quoted 24 lines

Hi,

latest dosemu has problems (locks up here and there) if it is run on a 2.4GHz pentium IV and inside dosemu.conf I have

$_rdtsc(on)
$_cpuspeed(0)

I think this comes from the fact that on startup it gives me a negative cpu speed

Kernel CPU speed is -1894957296Hz

I'm running a protect mode dos clipper program. Same system on a 2.0GHz cpu works flawlessly and it works ok as soon as I set rdtsc to off.

Also, there are problems with locks if I don't run it thruogh NETX on a novell server and, instead, I run it on my "C:" disk (which is a directory on my linux). I'll try to be more precise on the coming days.

regards.

--
__________

Quoted 7 lines
|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia
#2 lore raw
Quoted 6 lines

Any comments?

Nobody stumbled on this issue?

curious :)

I'd wager that nobody on this list owns a machine that fast. 8)

Quoted 2 lines
Quoted 2 lines

latest dosemu has problems (locks up here and there) if it is run on a 2.4GHz pentium IV and inside dosemu.conf I have

Signature · 1 line
Ryan Underwood, <nemesis at icequake.net>, icq=10317253
#3 lore raw

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

regards.

Ryan Underwood ha scritto:

Quoted 11 lines
Quoted 5 lines

Any comments?

Nobody stumbled on this issue?

curious :)

I'd wager that nobody on this list owns a machine that fast. 8)

Quoted 2 lines
Quoted 2 lines

latest dosemu has problems (locks up here and there) if it is run on a 2.4GHz pentium IV and inside dosemu.conf I have

Quoted 6 lines

--
Ryan Underwood, <nemesis at icequake.net>, icq=10317253
-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia
#4 lore raw
Quoted 4 lines · Maurilio Longo

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

it's a multiplication that overflows from an int -- try this patch:

src/base/init/config.c +1 -1
@@ -484,7 +484,7 @@
 		cdd[6]=0; sscanf(cdd,"%d",&df);
 		/* speed division factor to get 1us from CPU clocks - for
 		 * details on fast division see timers.h */
-		chz = (di * 1000000) + df;
+		chz = (di * 1000000LL) + df;
 
 		/* speed division factor to get 1us from CPU clock */
 		config.cpu_spd = (LLF_US*1000000)/chz;
#5 lore raw

Ok, with this patch it works ok :)

So I've switched to 1.1.4.13, but now my clipper program is not able to print to a serial printer anymore :( even if a

dir > com1:

from dos prompt works ok, but my program uses a third party library to communicate with serial devices

I fear it has to do with latest changes to serial code... I'll try to dig a little more, but I'm not familiar with dosemu code and linux programming in general...

regards.

Bart Oldeman ha scritto:

Quoted 12 lines · Maurilio Longo
Quoted 5 lines

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

it's a multiplication that overflows from an int -- try this patch:

src/base/init/config.c Wed Mar 12 14:38:28 2003 line 490

Quoted 8 lines
src/base/init/config.c Wed Mar 12 14:38:28 2003 renamed from src/base/init/config.c Sat Feb 15 14:49:31 2003 +1 -1
@@ -484,7 +484,7 @@
                cdd[6]=0; sscanf(cdd,"%d",&df);
                /* speed division factor to get 1us from CPU clocks - for
                 * details on fast division see timers.h */
-               chz = (di * 1000000) + df;
+               chz = (di * 1000000LL) + df;
 
                /* speed division factor to get 1us from CPU clock */
                config.cpu_spd = (LLF_US*1000000)/chz;

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia
#6 lore raw

Maurilio, were you using freedos with dosemu before you switched to 1.1.4.13 and your clipper apps were printing? In freedos? I never could put clipper printing (neither serial nor parallel) to work with freedos+dosemu, but I started to use dosemu with 1.1.4, and never tried any previous versions. Did the old versions of dosemu print from clipper apps using freedos? The only way I could put clipper apps to print using dosemu was using ms-dos or dr-dos... Norman

Maurilio Longo escreveu:

Quoted 61 lines

Ok, with this patch it works ok :)

So I've switched to 1.1.4.13, but now my clipper program is not able to print to a serial printer anymore :( even if a

dir > com1:

from dos prompt works ok, but my program uses a third party library to communicate with serial devices

I fear it has to do with latest changes to serial code... I'll try to dig a little more, but I'm not familiar with dosemu code and linux programming in general...

regards.

Bart Oldeman ha scritto:

Quoted 17 lines · Maurilio Longo
Quoted 9 lines

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

it's a multiplication that overflows from an int -- try this patch:

src/base/init/config.c Wed Mar 12 14:38:28 2003 line 490

Quoted 8 lines
src/base/init/config.c Wed Mar 12 14:38:28 2003 renamed from src/base/init/config.c Sat Feb 15 14:49:31 2003 +1 -1
@@ -484,7 +484,7 @@
               cdd[6]=0; sscanf(cdd,"%d",&df);
               /* speed division factor to get 1us from CPU clocks - for
                * details on fast division see timers.h */
-               chz = (di * 1000000) + df;
+               chz = (di * 1000000LL) + df;
 
               /* speed division factor to get 1us from CPU clock */
               config.cpu_spd = (LLF_US*1000000)/chz;

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#7 lore raw

No, I use an old MS-DOS 5.x, now, even with latest patch from Bart, I can print to my serial printer with a

dir > com1:

but not from my clipper (protect mode, telepathy as comx: access library) app...

To be more precise I can print very short strings, that is

tp_open(1...) // open com port 1
tp_send(1, "hi there") // send string
tp_close(1)

works, but if there are more tp_send() one after the other I get no output!?!!

1.1.1.x was working nicely

:(

regards.

Maurilio.

Regards.

Norman Schmidt Jr ha scritto:

Quoted 73 lines

Maurilio, were you using freedos with dosemu before you switched to 1.1.4.13 and your clipper apps were printing? In freedos? I never could put clipper printing (neither serial nor parallel) to work with freedos+dosemu, but I started to use dosemu with 1.1.4, and never tried any previous versions. Did the old versions of dosemu print from clipper apps using freedos? The only way I could put clipper apps to print using dosemu was using ms-dos or dr-dos...
Norman

Maurilio Longo escreveu:

Quoted 49 lines

Ok, with this patch it works ok :)

So I've switched to 1.1.4.13, but now my clipper program is not able to print to a serial printer anymore :( even if a

dir > com1:

from dos prompt works ok, but my program uses a third party library to communicate with serial devices

I fear it has to do with latest changes to serial code... I'll try to dig a little more, but I'm not familiar with dosemu code and linux programming in general...

regards.

Bart Oldeman ha scritto:

Quoted 17 lines · Maurilio Longo
Quoted 9 lines

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

it's a multiplication that overflows from an int -- try this patch:

src/base/init/config.c Wed Mar 12 14:38:28 2003 line 490

Quoted 8 lines
src/base/init/config.c Wed Mar 12 14:38:28 2003 renamed from src/base/init/config.c Sat Feb 15 14:49:31 2003 +1 -1
@@ -484,7 +484,7 @@
               cdd[6]=0; sscanf(cdd,"%d",&df);
               /* speed division factor to get 1us from CPU clocks - for
                * details on fast division see timers.h */
-               chz = (di * 1000000) + df;
+               chz = (di * 1000000LL) + df;
 
               /* speed division factor to get 1us from CPU clock */
               config.cpu_spd = (LLF_US*1000000)/chz;

--
__________

Quoted 12 lines
|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 4 lines

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia
#8 lore raw

That is,

int14 is working ok, but serial emulation is not (telepathy does a direct serial access and does not depend on int14 service).

regards

Maurilio Longo ha scritto:

Quoted 107 lines

No, I use an old MS-DOS 5.x, now, even with latest patch from Bart, I can print to my serial printer with a

dir > com1:

but not from my clipper (protect mode, telepathy as comx: access library) app...

To be more precise I can print very short strings, that is

tp_open(1...) // open com port 1
tp_send(1, "hi there") // send string
tp_close(1)

works, but if there are more tp_send() one after the other I get no output!?!!

1.1.1.x was working nicely

:(

regards.

Maurilio.

Regards.

Norman Schmidt Jr ha scritto:

Quoted 73 lines

Maurilio, were you using freedos with dosemu before you switched to 1.1.4.13 and your clipper apps were printing? In freedos? I never could put clipper printing (neither serial nor parallel) to work with freedos+dosemu, but I started to use dosemu with 1.1.4, and never tried any previous versions. Did the old versions of dosemu print from clipper apps using freedos? The only way I could put clipper apps to print using dosemu was using ms-dos or dr-dos...
Norman

Maurilio Longo escreveu:

Quoted 49 lines

Ok, with this patch it works ok :)

So I've switched to 1.1.4.13, but now my clipper program is not able to print to a serial printer anymore :( even if a

dir > com1:

from dos prompt works ok, but my program uses a third party library to communicate with serial devices

I fear it has to do with latest changes to serial code... I'll try to dig a little more, but I'm not familiar with dosemu code and linux programming in general...

regards.

Bart Oldeman ha scritto:

Quoted 17 lines · Maurilio Longo
Quoted 9 lines

I fear that cpu speed is inside a long int and this shoud explain why it happens, I'd

like to know from someone who writes dosemu if this is true and how they plan to fix this.

it's a multiplication that overflows from an int -- try this patch:

src/base/init/config.c Wed Mar 12 14:38:28 2003 line 490

Quoted 8 lines
src/base/init/config.c Wed Mar 12 14:38:28 2003 renamed from src/base/init/config.c Sat Feb 15 14:49:31 2003 +1 -1
@@ -484,7 +484,7 @@
               cdd[6]=0; sscanf(cdd,"%d",&df);
               /* speed division factor to get 1us from CPU clocks - for
                * details on fast division see timers.h */
-               chz = (di * 1000000) + df;
+               chz = (di * 1000000LL) + df;
 
               /* speed division factor to get 1us from CPU clock */
               config.cpu_spd = (LLF_US*1000000)/chz;

--
__________

Quoted 12 lines
|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 4 lines

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
__________

Quoted 7 lines
|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia

-
To unsubscribe from this list: send the line "unsubscribe linux-msdos" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
__________

|  |  | |__| [email protected]
|_|_|_|____| Team OS/2 Italia