Jump to content
Sign in to follow this  
Schampi

Error With Xorfwf

Recommended Posts

Bug description:

The ASM-command XORWF is not supported by the integrated assembler of BoostC.

 

Steps to reproduce:

1.) Create a new project

2.) Add a main.c file to the project with the following code

1	#include <system.h>
2
3	char var_1 = 11110000b;
4	char var_2 = 10101010b;
5	char var_3 = 000000000;
6
7	void main()
8	{
9  asm
10  {
11 	 movf _var_1,W
12 	 xorwf _var_2,W
13 	 movwf _var_3	; expected result var_3 = 01011010b
14 	 movf _var_1,W
15 	 xorwf _var_2,F; expected result var_2 = 01011010b
16  }
17  while(1)
18  {
19 	 clear_wdt();
20  }
21	}

3.) Compile and link the project using BoostC

 

Compiling...

 

C:\Programme\SourceBoost\boostc.pic16.exe -t PIC16F877  Test_XORWF.c

 

BoostC Optimizing C Compiler Version 1.5 Alpha (for PIC16 architecture)

http://www.picant.com/c2c/c.html

Copyright© 2004 Pavel Baranov

Copyright© 2004 David Hobday

 

 

Test_XORWF.c(12): error: error in built-in assembly

Test_XORWF.c(15): error: error in built-in assembly

Failure

Done

 

Expected behaviour:

The compilation process should be finished successfully.

 

The problem is 100% reproducible using the following setting

 

IDE version: 5.6.1

Compiler: BoostC

Compiler version: 1.5 Alpha

Target device: PIC 16F877

OS: MS XP Professional SP2

 

Comments:[\b]

  • It's possible to compile the above mentioned code using the C2C-plus compiler
  • This bug was already posted on the Oct 8 2004, 01:12 PM by uuzh, but never answered.

Share this post


Link to post
Share on other sites

I see what's wrong. Fix will be available is soon to be released SourceBoost 5.7 & BoostC 1.6 release.

 

Regards,

Pavel

Share this post


Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...