Reputation: 33
The compilation was successful
The multiplication should have been performed at compile time without any code being generated.
However, your solution generated the following code:
Java HotSpot(TM) 64-Bit Server VM warning: Can't detect initial thread stack location - find_vma failed
mov ax,5
mov ax,6
mul ax
[ the expected value was 30, but you calculated the result as 6 ]
I entered some code in my school's system and I got this error message. I don't understand the part where it says "The multiplication should have been performed at compile time without any code being generated.".
Anyone know what I might be doing wrong?
(I can't reveal the code I entered in it, because I don't want it showing up in a search engine. Is there a way I can privately show the code I entered in?)
Upvotes: 3
Views: 7750
Reputation: 6026
I encountered the same problem in my chroot
environment. As @chronospoon suggested, it is because java was unable to access the /proc filesystem.
However, the correct mounting command is the following (note that both proc does not prefixed by /
), as mentioned in here:
mount -t proc none proc
To check whether the mounting is successful, just check whether the proc
directory has any file.
Upvotes: 3
Reputation: 637
On my Ubuntu 10.04/64-bit system, java
was unable to access the /proc
filesystem.
Specifically, I was running in a chroot
which didn't have it mounted:
mount -t proc none /proc
Upvotes: 15
Reputation: 46482
The message "Can't detect initial thread stack location" is quite common, see e.g., here and here. The remaining part is strange, the assembly code is pure nonsense. I wouldn't care about that, it isn't your fault.
Upvotes: 1
Reputation: 38787
The Can't detect initial thread stack location
suggests an incomplete or corrupt Java installation.
The stuff about multiplication at compile time doesn't look like it comes from Java, but instead from some sort of IDE or compilation tool that your school is using. Whatever this "school system" is, you need to ask whoever is responsible for it about these error messages.
Upvotes: 0
Reputation: 719309
I suspect that this is an artifact of the "school system" that you are using, which appears to be some framework for automating code testing.
So, I think you should be asking the people who manage the system, and (presumably) understand what that message means.
Upvotes: 0