Closed joemonk64 closed 7 years ago
How is this a bug ?
Why is hercules starting up in a mode other than what I specified in its config file?
What does it matter ? Once the configuration file is processed, the configuration of the system matches the configuration statements.
Because we're activating features and functionality that shouldn't be turned on in the first place for the mode.
For instance, if I start the CPU in z/Arch, that activates 64-bit support. Yet S/370 doesn't have a clue about 64-bit. So why turn on all the 64-bit code only to have to turn it off? Why not just not activate it to begin with?
The system will be in S/370 architecture mode with S/370 features at the end of the processing of the configuration file. Whatever processing occurs and whatever intermediate state the system goes through during Power On/IML is irrelevant.
Joe, You also have to realize.. First, setting the architecture mode in the config file basically just sets a few flags in the SYSBLK control block (structure) and emits a message to the console. This affects how the CPU is run (what cpu_run version to dispatch) when the system is eventually IPLed or a SYSTEM RESTART occurs.
Second, the reason it occurs this is way is because configuration statements (besides device statements) are basically console commands. So when hercules starts, the architecture is set to an arbitrary architecture. The architecture that is to be used when Power On Reset is complete (when hercules has completed initialization) is then set by the ARCHLVL command.
Third, an architecture switch may occur 'mid flight' due to a SIGP instruction or an IPL manual control. For example, if you have a z/Arch OS and define ARCHLVL z/Arch, you will see upon IPL the system starting as z/Arch, going to ESA/390 mode (because of IPL), then back to z/Arch mode (because of SIGP).
Alright, I'm going to close this for now.
When Hercules starts up, it appears the defaults are being taken first and then the config file is being applied, versus starting up in the specified mode.
Example...
Config file:
ARCHLVL S/370 CPUMODEL 3083 MAINSIZE 8
Hercules Startup:
HHC00811I Processor CP00: architecture mode z/Arch
HHC00811I Processor CP00: architecture mode S/370
HHC00100I Thread id 00002708, prio -20, name Timer started
HHC02204I archmode set to S/370 HHC17003I MAIN storage is 8M (mainsize); storage is not locked
HHC02204I cpumodel set to 3083
HHC00100I Thread id 00001bd4, prio 0, name Control panel started
As we can see the ARCHLVL was set to z/Arch even though I specified S/370 in config file. Then the config file was applied and the ARCHLVL, CPUMODEL and MAINSIZE were set.