Go to Post At IRI you have 72 of the best teams in the country. It could literally be held in a cornfield in the middle of Indiana and nobody would care, because the competition is simply that good. - Cory [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 19-12-2011, 17:54
WizenedEE's Avatar
WizenedEE WizenedEE is offline
Registered User
AKA: Adam
FRC #3238 (Cyborg Ferrets)
Team Role: Leadership
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Anacortes, WA
Posts: 395
WizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to all
UCPP Error

Hi, I'm having some problems with the ucpp project. I'm running arch linux, with wine version 1.3.35 and no programs installed into it except for whatever ucpp did. Here's what I did:

I downloaded the zip file from https://github.com/nikitakit/ucpp, unzipped it, then moved it to /home/adam I added /home/adam/ucpp/ucpp to my path, installed wine and wine_gecko (using pacman), then went to the directory where my c++ project is. There are three header files, two with constants and one is the header file for main, and main.cpp; and two directories with other classes. I typed:
Code:
$ ucpp setup -t 3238
$ ucpp configure
and got an error about bash not recognizing commands in ucpp_gen_makefile.py, so I added
Code:
#! /usr/bin/env python2
to the top of both that file and the gen_wpilib_makefile file.
I ran
Code:
$ ucpp configure
with no errors, and then I ran
Code:
$ make
which outputted the normal things that make does ("building... "), but an error message window popped up and said that nmppc had a serious error and crashed. On the terminal window, the error was:
Code:
building 2011-12-19-0_partialImage/Debug/2011-12-19-0_partialImage.o
building 2011-12-19-0/Debug/2011-12-19-0.out
wine: Unhandled page fault on read access to 0x6e795373 at address 0x7bc48b8b (thread 0023), starting debugger...
Unhandled exception: page fault on read access to 0x6e795373 in 32-bit code (0x7bc48b8b).
Register dump:
 CS:0073 SS:007b DS:007b ES:007b FS:0033 GS:003b
 EIP:7bc48b8b ESP:0067fc10 EBP:0067fc58 EFLAGS:00010202(  R- --  I   - - - )
 EAX:00000f10 EBX:7bcb6ff4 ECX:00000000 EDX:00116c80
 ESI:6e795373 EDI:00110014
Stack dump:
0x0067fc10:  00000200 00000370 7bc48891 7bc485ce
0x0067fc20:  00000004 7edebc40 0067fc48 7bc37321
0x0067fc30:  00000f0a 00000f10 0067fc98 00000f10
0x0067fc40:  00110060 7edec620 0067fc68 7bcb6ff4
0x0067fc50:  00110000 00000002 0067fcb8 7bc4923e
0x0067fc60:  00116c80 7ede3ff4 0067fc98 7ed92c53
Backtrace:
=>0 0x7bc48b8b in ntdll (+0x38b8b) (0x0067fc58)
  1 0x7bc4923e RtlFreeHeap+0x7d() in ntdll (0x0067fcb8)
  2 0x7ed8e926 MSVCRT_free+0x25() in msvcrt (0x0067fcd8)
  3 0x00455eba in nmppc (+0x55eb9) (0x0067fcf8)
  4 0x0040b5d5 in nmppc (+0xb5d4) (0x0067fd08)
  5 0x00409505 in nmppc (+0x9504) (0x0067fd18)
  6 0x00409760 in nmppc (+0x975f) (0x0067fd78)
  7 0x00402def in nmppc (+0x2dee) (0x0067fde8)
  8 0x0040339e in nmppc (+0x339d) (0x0067fe28)
  9 0x004011e7 in nmppc (+0x11e6) (0x0067fe60)
  10 0x00401238 in nmppc (+0x1237) (0x0067fe70)
  11 0x7b859b1c call_process_entry+0xb() in kernel32 (0x0067fe88)
  12 0x7b85adaf in kernel32 (+0x4adae) (0x0067fec8)
  13 0x7bc74550 call_thread_func_wrapper+0xb() in ntdll (0x0067fed8)
  14 0x7bc7735d call_thread_func+0x7c() in ntdll (0x0067ffa8)
  15 0x7bc7452e RtlRaiseException+0x21() in ntdll (0x0067ffc8)
  16 0x7bc4bc5e call_dll_entry_point+0x33d() in ntdll (0x0067ffe8)
  17 0xb76e99bd wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
0x7bc48b8b: movl	0x0(%esi),%edx
Modules:
Module	Address			Debug info	Name (16 modules)
PE	  400000-  47a000	Export          nmppc
ELF	7b800000-7b9c4000	Dwarf           kernel32<elf>
  \-PE	7b810000-7b9c4000	\               kernel32
ELF	7bc00000-7bcd3000	Dwarf           ntdll<elf>
  \-PE	7bc10000-7bcd3000	\               ntdll
ELF	7bf00000-7bf04000	Deferred        <wine-loader>
ELF	7ed52000-7eded000	Dwarf           msvcrt<elf>
  \-PE	7ed70000-7eded000	\               msvcrt
ELF	7efb2000-7efbf000	Deferred        libnss_files.so.2
ELF	7efbf000-7efe9000	Deferred        libm.so.6
ELF	b752c000-b7531000	Deferred        libdl.so.2
ELF	b7531000-b76ae000	Deferred        libc.so.6
ELF	b76ae000-b76c9000	Deferred        libpthread.so.0
ELF	b76e0000-b7823000	Dwarf           libwine.so.1
ELF	b7824000-b7845000	Deferred        ld-linux.so.2
ELF	b7845000-b7846000	Deferred        [vdso].so
Threads:
process  tid      prio (all id:s are in hex)
0000000e services.exe
	0000001e    0
	0000001d    0
	00000019    0
	00000017    0
	00000015    0
	00000010    0
	0000000f    0
00000012 winedevice.exe
	00000018    0
	00000014    0
	00000013    0
0000001a plugplay.exe
	0000001f    0
	0000001c    0
	0000001b    0
00000020 explorer.exe
	00000021    0
00000026 licproxy.exe
	00000027    0
0000000b (D) Z:\home\adam\.ucpp\gccdist\WindRiver\gnu\3.4.4-vxworks-6.3\x86-win32\bin\nmppc.exe
	00000023    0 <==
Backtrace:
=>0 0x7bc48b8b in ntdll (+0x38b8b) (0x0067fc58)
  1 0x7bc4923e RtlFreeHeap+0x7d() in ntdll (0x0067fcb8)
  2 0x7ed8e926 MSVCRT_free+0x25() in msvcrt (0x0067fcd8)
  3 0x00455eba in nmppc (+0x55eb9) (0x0067fcf8)
  4 0x0040b5d5 in nmppc (+0xb5d4) (0x0067fd08)
  5 0x00409505 in nmppc (+0x9504) (0x0067fd18)
  6 0x00409760 in nmppc (+0x975f) (0x0067fd78)
  7 0x00402def in nmppc (+0x2dee) (0x0067fde8)
  8 0x0040339e in nmppc (+0x339d) (0x0067fe28)
  9 0x004011e7 in nmppc (+0x11e6) (0x0067fe60)
  10 0x00401238 in nmppc (+0x1237) (0x0067fe70)
  11 0x7b859b1c call_process_entry+0xb() in kernel32 (0x0067fe88)
  12 0x7b85adaf in kernel32 (+0x4adae) (0x0067fec8)
  13 0x7bc74550 call_thread_func_wrapper+0xb() in ntdll (0x0067fed8)
  14 0x7bc7735d call_thread_func+0x7c() in ntdll (0x0067ffa8)
  15 0x7bc7452e RtlRaiseException+0x21() in ntdll (0x0067ffc8)
  16 0x7bc4bc5e call_dll_entry_point+0x33d() in ntdll (0x0067ffe8)
  17 0xb76e99bd wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
make: built targets of /home/adam/team3238/2011robotcode/cpp/2011-12-19-0/PPC603gnu
A few seconds later, after the next prompt had showed up, I got another error message:
Code:
err:ntdll:RtlDeleteResource Deleting active MRSW lock (0x111f64), expect failure
The first problem shows up only when everything compiles with no errors (it shows up when there are warnings though). It doesn't show up when everything is already compiled (ie make doesn't do anything). The second problem appears to show up randomly.

Since I don't have a cRIO handy, I'm not sure if this is actually affecting the outputted code or the deploy function.

Hopefully I can get an answer to what the problem is or help the developer fix something.
  #2   Spotlight this post!  
Unread 19-12-2011, 20:19
AustinSchuh AustinSchuh is offline
Registered User
FRC #0971 (Spartan Robotics) #254 (The Cheesy Poofs)
Team Role: Engineer
 
Join Date: Feb 2005
Rookie Year: 1999
Location: Los Altos, CA
Posts: 803
AustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond repute
Re: UCPP Error

Can you post the code that you were building?

My guess is that Wine had a regression. Can you try another version of Wine?

Keep this thread up to date, and we/I will do our best to help. If you are having problems, then it isn't perfect yet.
  #3   Spotlight this post!  
Unread 19-12-2011, 20:51
WizenedEE's Avatar
WizenedEE WizenedEE is offline
Registered User
AKA: Adam
FRC #3238 (Cyborg Ferrets)
Team Role: Leadership
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Anacortes, WA
Posts: 395
WizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to all
Re: UCPP Error

Here's the code. It has a few warnings, sorry about that. I'll see if I can downgrade, but it would be pretty tricky.
Attached Files
File Type: zip 2011-12-19-0.zip (1.35 MB, 8 views)
  #4   Spotlight this post!  
Unread 20-12-2011, 01:49
mesamb1's Avatar
mesamb1 mesamb1 is offline
Registered User
AKA: Sam Bacon
FRC #1466 (Webb Robotics)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2004
Location: Knoxville
Posts: 93
mesamb1 is just really nicemesamb1 is just really nicemesamb1 is just really nicemesamb1 is just really nice
Re: UCPP Error

Let me start with the doozey. Not a make export, and defiantly not a wine expert.

Now here is what I think
Quote:
Originally Posted by WizenedEE View Post
Code:
building 2011-12-19-0_partialImage/Debug/2011-12-19-0_partialImage.o
building 2011-12-19-0/Debug/2011-12-19-0.out
wine: Unhandled page fault on read access to 0x6e795373 at address 0x7bc48b8b (thread 0023), starting debugger...
Unhandled exception: page fault on read access to 0x6e795373 in 32-bit code (0x7bc48b8b).
Register dump:
 CS:0073 SS:007b DS:007b ES:007b FS:0033 GS:003b
 EIP:7bc48b8b ESP:0067fc10 EBP:0067fc58 EFLAGS:00010202(  R- --  I   - - - )
 EAX:00000f10 EBX:7bcb6ff4 ECX:00000000 EDX:00116c80
 ESI:6e795373 EDI:00110014
Stack dump:
0x0067fc10:  00000200 00000370 7bc48891 7bc485ce
0x0067fc20:  00000004 7edebc40 0067fc48 7bc37321
0x0067fc30:  00000f0a 00000f10 0067fc98 00000f10
0x0067fc40:  00110060 7edec620 0067fc68 7bcb6ff4
0x0067fc50:  00110000 00000002 0067fcb8 7bc4923e
0x0067fc60:  00116c80 7ede3ff4 0067fc98 7ed92c53
Backtrace:
=>0 0x7bc48b8b in ntdll (+0x38b8b) (0x0067fc58)
  1 0x7bc4923e RtlFreeHeap+0x7d() in ntdll (0x0067fcb8)
  2 0x7ed8e926 MSVCRT_free+0x25() in msvcrt (0x0067fcd8)
  3 0x00455eba in nmppc (+0x55eb9) (0x0067fcf8)
  4 0x0040b5d5 in nmppc (+0xb5d4) (0x0067fd08)
  5 0x00409505 in nmppc (+0x9504) (0x0067fd18)
  6 0x00409760 in nmppc (+0x975f) (0x0067fd78)
  7 0x00402def in nmppc (+0x2dee) (0x0067fde8)
  8 0x0040339e in nmppc (+0x339d) (0x0067fe28)
  9 0x004011e7 in nmppc (+0x11e6) (0x0067fe60)
  10 0x00401238 in nmppc (+0x1237) (0x0067fe70)
  11 0x7b859b1c call_process_entry+0xb() in kernel32 (0x0067fe88)
  12 0x7b85adaf in kernel32 (+0x4adae) (0x0067fec8)
  13 0x7bc74550 call_thread_func_wrapper+0xb() in ntdll (0x0067fed8)
  14 0x7bc7735d call_thread_func+0x7c() in ntdll (0x0067ffa8)
  15 0x7bc7452e RtlRaiseException+0x21() in ntdll (0x0067ffc8)
  16 0x7bc4bc5e call_dll_entry_point+0x33d() in ntdll (0x0067ffe8)
  17 0xb76e99bd wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
0x7bc48b8b: movl	0x0(%esi),%edx
Modules:
Module	Address			Debug info	Name (16 modules)
PE	  400000-  47a000	Export          nmppc
ELF	7b800000-7b9c4000	Dwarf           kernel32<elf>
  \-PE	7b810000-7b9c4000	\               kernel32
ELF	7bc00000-7bcd3000	Dwarf           ntdll<elf>
  \-PE	7bc10000-7bcd3000	\               ntdll
ELF	7bf00000-7bf04000	Deferred        <wine-loader>
ELF	7ed52000-7eded000	Dwarf           msvcrt<elf>
  \-PE	7ed70000-7eded000	\               msvcrt
ELF	7efb2000-7efbf000	Deferred        libnss_files.so.2
ELF	7efbf000-7efe9000	Deferred        libm.so.6
ELF	b752c000-b7531000	Deferred        libdl.so.2
ELF	b7531000-b76ae000	Deferred        libc.so.6
ELF	b76ae000-b76c9000	Deferred        libpthread.so.0
ELF	b76e0000-b7823000	Dwarf           libwine.so.1
ELF	b7824000-b7845000	Deferred        ld-linux.so.2
ELF	b7845000-b7846000	Deferred        [vdso].so
Threads:
process  tid      prio (all id:s are in hex)
0000000e services.exe
	0000001e    0
	0000001d    0
	00000019    0
	00000017    0
	00000015    0
	00000010    0
	0000000f    0
00000012 winedevice.exe
	00000018    0
	00000014    0
	00000013    0
0000001a plugplay.exe
	0000001f    0
	0000001c    0
	0000001b    0
00000020 explorer.exe
	00000021    0
00000026 licproxy.exe
	00000027    0
0000000b (D) Z:\home\adam\.ucpp\gccdist\WindRiver\gnu\3.4.4-vxworks-6.3\x86-win32\bin\nmppc.exe
	00000023    0 <==
Backtrace:
=>0 0x7bc48b8b in ntdll (+0x38b8b) (0x0067fc58)
  1 0x7bc4923e RtlFreeHeap+0x7d() in ntdll (0x0067fcb8)
  2 0x7ed8e926 MSVCRT_free+0x25() in msvcrt (0x0067fcd8)
  3 0x00455eba in nmppc (+0x55eb9) (0x0067fcf8)
  4 0x0040b5d5 in nmppc (+0xb5d4) (0x0067fd08)
  5 0x00409505 in nmppc (+0x9504) (0x0067fd18)
  6 0x00409760 in nmppc (+0x975f) (0x0067fd78)
  7 0x00402def in nmppc (+0x2dee) (0x0067fde8)
  8 0x0040339e in nmppc (+0x339d) (0x0067fe28)
  9 0x004011e7 in nmppc (+0x11e6) (0x0067fe60)
  10 0x00401238 in nmppc (+0x1237) (0x0067fe70)
  11 0x7b859b1c call_process_entry+0xb() in kernel32 (0x0067fe88)
  12 0x7b85adaf in kernel32 (+0x4adae) (0x0067fec8)
  13 0x7bc74550 call_thread_func_wrapper+0xb() in ntdll (0x0067fed8)
  14 0x7bc7735d call_thread_func+0x7c() in ntdll (0x0067ffa8)
  15 0x7bc7452e RtlRaiseException+0x21() in ntdll (0x0067ffc8)
  16 0x7bc4bc5e call_dll_entry_point+0x33d() in ntdll (0x0067ffe8)
  17 0xb76e99bd wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
make: built targets of /home/adam/team3238/2011robotcode/cpp/2011-12-19-0/PPC603gnu
almost all of that is a wine error, thanks to some googling and and a ubuntu forumhttp://ubuntuforums.org/showthread.php?t=820855(the section where they examine an error similar to yours is near the bottom of the page). I dont know if that is correct but seems like a reasonable answer. Sifting through the memory address I do see that it tries to call Windriver file, and would lead me to ask is Windriver installed? Based on the ubuntu forum I would wonder if that is the issue. a casual glance through you code brought no gapping errors to my attention.
  #5   Spotlight this post!  
Unread 20-12-2011, 02:31
AustinSchuh AustinSchuh is offline
Registered User
FRC #0971 (Spartan Robotics) #254 (The Cheesy Poofs)
Team Role: Engineer
 
Join Date: Feb 2005
Rookie Year: 1999
Location: Los Altos, CA
Posts: 803
AustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond repute
Re: UCPP Error

ucpp installs the compiler suite for Windriver automatically from a set of tools that NI puts out for free on their website. (Don't have the link handy, but you can read it from the source.) This smells like a wine regression to me, or a bug in nmppc triggered by something odd happening in wine.

It may take a day or so for me to poke at it, but I'll try my best to get back to you. (PM me or something if I forget...)
  #6   Spotlight this post!  
Unread 20-12-2011, 02:53
WizenedEE's Avatar
WizenedEE WizenedEE is offline
Registered User
AKA: Adam
FRC #3238 (Cyborg Ferrets)
Team Role: Leadership
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Anacortes, WA
Posts: 395
WizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to all
Re: UCPP Error

Just thought that it may be useful to try compiling my code on the "real" windriver and comparing it to what compiled on my machine and see if they're the same file.

Quote:
Originally Posted by mesamb1 View Post
and would lead me to ask is Windriver installed? Based on the ubuntu forum I would wonder if that is the issue. a casual glance through you code brought no gapping errors to my attention.
Windriver itself is not installed; I'm running linux and have never put the DVD in. However, it may be that I tried to remove and redownload ucpp several times. When I did that, I would remove the downloaded ucpp folder and ~/.ucpp, plus whatever extra stuff was put in the project's directory -- is there another place that could be conflicting?

Quote:
It may take a day or so for me to poke at it, but I'll try my best to get back to you.
Thank you!

EDIT: Downgrading wine to 1.3.8 seemed to have fixed the problem. I assume you'll want to submit a bug report to the wine developers

Last edited by WizenedEE : 20-12-2011 at 03:16. Reason: Added info
  #7   Spotlight this post!  
Unread 20-12-2011, 03:31
AustinSchuh AustinSchuh is offline
Registered User
FRC #0971 (Spartan Robotics) #254 (The Cheesy Poofs)
Team Role: Engineer
 
Join Date: Feb 2005
Rookie Year: 1999
Location: Los Altos, CA
Posts: 803
AustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond reputeAustinSchuh has a reputation beyond repute
Re: UCPP Error

Quote:
Originally Posted by WizenedEE View Post
Downgrading wine to 1.3.8 seemed to have fixed the problem.
Glad to hear it!
  #8   Spotlight this post!  
Unread 04-02-2012, 03:02
WizenedEE's Avatar
WizenedEE WizenedEE is offline
Registered User
AKA: Adam
FRC #3238 (Cyborg Ferrets)
Team Role: Leadership
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Anacortes, WA
Posts: 395
WizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to all
Re: UCPP Error

The regression still exists in wine 1.4
  #9   Spotlight this post!  
Unread 26-02-2012, 14:55
WizenedEE's Avatar
WizenedEE WizenedEE is offline
Registered User
AKA: Adam
FRC #3238 (Cyborg Ferrets)
Team Role: Leadership
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Anacortes, WA
Posts: 395
WizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to allWizenedEE is a name known to all
Re: UCPP Error

With the lastest version of ucpp and wine, everything compiles successfully and I get no errors (and I don't have to modify the files I said in the last post). I have not tried downloading code to a robot, though.

Thanks for all your hard work! It's great to even check for syntax errors without getting errors about "CANJaguar is not a type"
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 01:06.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi