flat assembler
Message board for the users of flat assembler.

Index > Main > [solved] Public is an illegal instruction

Author
Thread Post new topic Reply to topic
crank123



Joined: 02 May 2015
Posts: 2
crank123
I have a program that contains the following line:
Code:
public start as '_start'    

however when I compile it I get this error
Quote:

flat assembler version 1.71.39 (16384 kilobytes memory)
arch/x86_64/boiler.asm [8]:
public start as '_start'
error: illegal instruction.

I have also tried:
Code:
public start    

but I get the same error.

Can anyone tell me why this is happening. Oh, and if I did anything wrong please be polite about it. I am new to this forum. Well, I've been here before, but just viewing.
Post 02 May 2015, 05:48
View user's profile Send private message Visit poster's website Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17492
Location: In your JS exploiting you and your system
revolution
You have to set the output format correctly for public to be usable. Unfortunately you haven't given enough detail in the code you posted for us to determine what is actually wrong.
Post 02 May 2015, 05:55
View user's profile Send private message Visit poster's website Reply with quote
crank123



Joined: 02 May 2015
Posts: 2
crank123
Sorry, here's all of it:

Code:
use64

public start as '_start'
extrn os_main

start:
  call os_main ; Calls the main function in the Cs file

  cli  ; Clear interrupts
  hlt ; Halt the CPU    


However, specifying a format fixed it! Thank you!
Post 02 May 2015, 05:56
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.