Perl 6 - the future is here, just unevenly distributed

IRC log for #perl11, 2013-11-12

| Channels | #perl11 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:01 rurban1 joined #perl11
00:08 mirjam joined #perl11
00:41 stevan joined #perl11
00:48 Will_the_Chill joined #perl11
01:23 rurban1 joined #perl11
01:29 rurban2 joined #perl11
02:30 rurban1 joined #perl11
02:54 rurban1 joined #perl11
03:13 bulk88 Will_the_chill "All benchmarks were run in serial under identical conditions on a Dell Latitude D630 with an 800MHz Intel Core2 Duo processor " 800 mhz? did you lock power management cpu speed or something? and how does someone reproduce your benchmarks? where is the code?
03:55 rurban1 joined #perl11
05:01 rurban1 joined #perl11
05:06 mirjam joined #perl11
05:07 Will_the_Chill bulk88: I ran the benchmarks on my laptop, the specs you quote were produced by running the "linux_logo" utility from the command line.
05:07 Will_the_Chill the RPerl code has been on github for a while.
05:08 Will_the_Chill there is a bin/ directory and also a t/ directory
05:09 bulk88 which file did you run?
05:11 Will_the_Chill I ran those tests on 6/16/13, the most recent code work has been to build the tests and data structures, I may have introduced bugs into the bubblesort code since then, you might have to go back to one of the previous git snapshots to get the runnable benchmark code
05:11 Will_the_Chill the file is bin/multi_sort.pl
05:12 Will_the_Chill near the top of multi_sort.pl there is a line to choose between pure Perl and RPerl, it is the 2 lines following the comment
05:12 Will_the_Chill # supported algorithms
05:15 bulk88 lets see if anything will run on Windows :-p
05:16 Will_the_Chill once you comment out pure Perl and uncomment RPerl, then you have the further choice of RPerl's Perl data mode (7x speedup) or RPerl's C/C++ data mode (200x speedup)
05:17 Will_the_Chill this setting is in the file lib/types.h under the comment
05:17 Will_the_Chill / <<< TYPE DEFINES >>>
05:17 Will_the_Chill I would love to have somebody on Windows testing out my code, I only have Linux.  :)
05:18 Will_the_Chill the tests in the t/ directory run for me on Linux in the latest github snapshot
05:18 Will_the_Chill my next step is to integrate the bubblesort benchmark into those tests
05:18 Will_the_Chill should have it done in a few days
05:19 Will_the_Chill but like I said, haven't run the bubblesort in a while since updating some of the code, so you may have to roll back to older RPerl code for that particular benchmarks
05:27 bulk88 why are you patching Inline::Filters?
05:28 Will_the_Chill because it is broken
05:29 Will_the_Chill ingy: I need to submit a patch to Inline::Filters, does that go to you?
05:30 Will_the_Chill bulk88: search for the tag WBRASWELL in Filters.pm
05:31 bulk88 https://github.com/wbraswell/rperl/blob/master/lib/CPAN/MyConfig.pm I wish CPAN remembered to ask the user for the root password if it didn't store it already in MyConfig.pm, it will make install system wide modules more user friendly ;-)
05:31 Will_the_Chill it is a problem with the Inline::Filters pre-processor not correctly handling the INC variable
05:32 bulk88 why aren't you using use lib?
05:32 Will_the_Chill I designed RPerl to be run by an individual user who may not have system-wide permissions
05:33 Will_the_Chill regarding "use lib", IIRC there were all kinds of slippery problems with the Perl include paths being unpredictable
05:33 Will_the_Chill whatever I came up with is what worked
05:33 Will_the_Chill I was not happy with the need to do all the hand-waving but at least it runs
05:34 Will_the_Chill and it runs without needing to have system-wide permissions
05:34 bulk88 is RPerl actually installable or it always runs "uninstalled" at the moment?
05:34 Will_the_Chill the installation and configuration is a specific aspect of RPerl that I desperately need help with
05:35 Will_the_Chill there is a primitive install doc
05:35 Will_the_Chill docs/install_notes.txt
05:35 Will_the_Chill it needs to be automated of course
05:35 bulk88 that install doc is so bad it needs to be blindfolded and executed
05:36 Will_the_Chill one of the few remaining sections of the rperl.org website that I need to build is the "how to install and use RPerl" section
05:36 Will_the_Chill that install doc is almost a shell script  XD
05:36 Will_the_Chill like I said, I'll be updating the install doc in the immediate future
05:37 bulk88 paste?
05:37 bulk88 no bots :-(
05:38 Will_the_Chill huh?  paste what?  bots what?
05:38 bulk88 http://pastebin.com/wvQnLkPv
05:39 Will_the_Chill you're doing it wrong.  ;)
05:39 Will_the_Chill you have to set up the links (or the Windows equivalent) as shown in the install doc
05:39 Will_the_Chill so that MyConfig.pm can be found and everything kicks off from there
05:40 Will_the_Chill in my 15+ years of Perl all my code has been proprietary, so I have never released any code on CPAN.  I need guidance on how to get from where I'm at now to something polished enough to go on CPAN.  help please?  :)
05:40 bulk88 no shadowpaste the bot here, shadowpaste is a bot on irc.perl.org, she lives in a couple of rooms, many rooms have shadowpaste in them
05:41 bulk88 do a /whois shadowpaste
05:43 bulk88 " <Will_the_Chill> in my 15+ years of Perl all my code has been proprietary, so I have never released any code on CPAN.  I need guidance on how to get from where I'm at now to something polished enough to go on CPAN.  help please?  :)" I want to say try #perl-help :-p
05:43 Will_the_Chill I typed "/whois shadowpaste" and nothing happened
05:43 bulk88 http://pastebin.com/xGcAgBGq now I'm doing it correctly for an "uninstalled" module
05:43 Will_the_Chill #perl-help isn't going to care enough to give me the detailed feedback I need
05:44 Will_the_Chill when you say you're "doing it correctly" but then show me another "can't locate MyConfig" error, then all I can say is you must NOT be doing is correctly.  ;)
05:44 bulk88 http://pastebin.com/YZV8HjR6
05:45 Will_the_Chill did you read through the install doc?
05:45 Will_the_Chill I know it is horrible but it does contain the information to get it working in Linux, at least.
05:46 bulk88 there is no way I'm patching my system CPAN profile to run any module
05:47 bulk88 .. or env vars is how you portably do path management
05:48 Will_the_Chill uh?  like I said this shouldn't change anything on your system!
05:48 Will_the_Chill run is as a non-admin user!
05:48 Will_the_Chill it should download and install whatever it needs into a user directory
05:49 Will_the_Chill for example, everything installs and runs from /home/wbraswell/RPerl/3rd_party/CPAN/ for me
05:49 Will_the_Chill nothing changed on the system wide anything
05:51 bulk88 $ cd ~/.cpan/CPAN # "C:\Documents and Settings\Owner\.cpan\CPAN" on my system
05:51 bulk88 $ mv MyConfig.pm MyConfig.pm.old # backup my global cpan config file(there are no other users or .cpan folders on my system)
05:51 bulk88 $ ln -s path/to/RPerl/lib/CPAN/MyConfig.pm MyConfig.pm #copy (since sym links dont exist) git tracked MyConfig.pm over the global MyConfig.pm
05:52 Will_the_Chill I'm not sure if you're asking me something?
05:52 Will_the_Chill and I'm not sure what "git tracked ..." means?
05:52 bulk88 I dont know if I am asking something
05:53 Will_the_Chill are you telling me you can't figure out how to get MyConfig to load correctly?
05:53 bulk88 git tracked means it is a file in the RPerl github tree, and it is tracked/versioned by git
05:53 bulk88 why does RPerl need to use CPAN?
05:54 Will_the_Chill Inline::C, Inline::CPP and their dependencies
05:54 Will_the_Chill and maybe some other stuff I forgot, but those are the main ones
05:54 Will_the_Chill I tried my best to make RPerl not be dependent on anything other than Inline
05:55 Will_the_Chill the only other CPAN module I can remember that RPerl needs is Test::Exception
05:55 bulk88 I'll start changing multi_sort.t
05:55 Will_the_Chill AWESOME!
05:56 Will_the_Chill do I need to do something special in github to give you permission to upload your changes?
05:56 bulk88 I didn't publically fork it on github since I'm not planning to do any changes ATM
05:56 bulk88 got multi_sort.t to run
05:56 Will_the_Chill wow that was fast
05:56 bulk88 but it failed with a screen of errors
05:56 Will_the_Chill oh
05:57 Will_the_Chill haha
05:57 Will_the_Chill well that may be due to updates to the type system, as mentioned
05:57 bulk88 http://pastebin.com/7vbi3Sw4
05:58 Will_the_Chill in the past I've just run multi_sort.pl directly, FYI
05:59 Will_the_Chill I encoded the error message into the failure: "/FAILURE/BECAUSE/RPERL/INCLUDE/PATH/NOT/YET/SET/"
05:59 bulk88 what I did to get multi_sort.t to run, the only change http://pastebin.com/i7CfsJna
06:00 Will_the_Chill okay I'm gonna say again, I've not completed work on multi_sort.t, so don't use it
06:00 Will_the_Chill run multi_sort.pl directly please
06:00 Will_the_Chill I think?
06:00 Will_the_Chill oh gosh I don't know
06:00 bulk88 " in the past I've just run multi_sort.pl directly, FYI" .pl is not executable on Windows shell, it would have to be a Windows "shell script" to be executable, since # doesn't exist
06:01 Will_the_Chill for reals you need to start first by running "01_depend.t" and work up step-by-step from there
06:01 Will_the_Chill if 01_depend.t doesn't work, the system is not configured properly
06:02 bulk88 some Windows people could also use "start someperlfile.pl" on the command prompt, that would use Explorer/Windows GUI's file associations, but .pl goes to my IDE in that case, not the perl interp, for safety reasons
06:02 Will_the_Chill okay I'm confused now.  there is no such file named "multi_sort.t"
06:02 Will_the_Chill so I assume everything you've been talking about is only "multi_sort.pl"?
06:02 bulk88 https://github.com/wbraswell/rperl/blob/master/bin/multi_sort.pl
06:03 Will_the_Chill okay, that clears up one confusion!
06:03 bulk88 oh shit
06:03 bulk88 was I saying multi_sort.t?
06:03 Will_the_Chill yes you were saying multi_sort.t, no prob, just confused me!  :)
06:04 Will_the_Chill you must start with the low-number tests in t/ to even know if your system is set up correctly
06:04 Will_the_Chill if not I have no idea what's actually going wrong in your test
06:05 Will_the_Chill AND even if all the tests run correctly up through "05_type_hash.t", then multi_sort.pl may STILL not work with this latest github code, and you may have to roll back
06:05 Will_the_Chill sorry for the frustration, this is literally next up on my list.  :)
06:06 Will_the_Chill https://trello.com/b/hQCPeg1d/austin-pm-rperl-development
06:06 Will_the_Chill but I can tell you right now you don't stand a chance getting multi_sort.pl to work if the other low-number tests don't work.
06:07 Will_the_Chill according to my to-do list, re-configuring MyConfig and @INC for bubblesort is next up on the chopping block
06:08 bulk88 http://pastebin.com/rtGUNghE 01_depend.t
06:08 bulk88 before and after fixing
06:10 bulk88 inline::C is crap http://pastebin.com/12X8gCUJ
06:11 bulk88 handling file paths like its 1975
06:11 Will_the_Chill the first one says "this paste has been removed"
06:11 bulk88 what was the complete message I included that link in?
06:12 Will_the_Chill http://pastebin.com/rtGUNghE 01_depend.t DOESN'T WORK
06:12 Will_the_Chill http://pastebin.com/12X8gCUJ DOES WORK
06:12 Will_the_Chill oh wait the error was on my end, they both work, sorry!
06:13 Will_the_Chill I don't know what to say about the directory handling issues, it works on Linux.  :P
06:13 Will_the_Chill Also, Inline::C is Ingy's baby.  Blame him?  HAHA!
06:13 Will_the_Chill ingy: you're "handling file paths like its 1975" according to bulk88!  :)
06:13 bulk88 http://pastebin.com/peah8AvR 01_depend.t runs, before and after patching
06:16 bulk88 http://pastebin.com/i3iQCAV6 my changes to RPerl so far
06:16 bulk88 test them on your system
06:16 bulk88 notice the ".." means cwd relative
06:17 bulk88 https://rt.cpan.org/Public/Bug/Display.html?id=67053
06:18 bulk88 Inline::C failed a make test when I cpan shell installed it
06:19 Will_the_Chill clearly Inline::C needs some TLC  :)
06:20 bulk88 fixed the inline::C problems by moving RPerl to my spaceless directory
06:20 bulk88 now have a segv
06:21 Will_the_Chill YAY segfault you're doing it right!  ;)
06:21 Will_the_Chill (spaces in directories and file names, tsk tsk tsk)
06:22 bulk88 http://pastebin.com/G3HfrwvH
06:23 Will_the_Chill "Free to wrong pool" I don't think I've ever seen that error!
06:29 bulk88 its is windows only, think of it as a valgrind failure ;-)
06:29 bulk88 Win32 Perl by default, because of ithreads, doesn't allow mixing of different memory allocators
06:29 bulk88 it also doesn't allow double frees
06:30 bulk88 or reallocs on things from different allocators
06:30 bulk88 Windows has about 15 different memory allocators I can name off the top of my head
06:31 Will_the_Chill okay well all that sounds kinda foreign to me.
06:32 bulk88 new!=Newx!=SvPVX!=malloc!=HeapAlloc
06:32 Will_the_Chill your changes to 01_...t and 02...t have been accepted!
06:32 bulk88 "each CRT (VS 2, 3, 4, 5, NT/6, 7.0, 7.1, 8, 9, 10) malloc, LocalAlloc, GlobalAlloc, HeapAlloc, (each version of C++ Runtime Library) "new", CoGetMalloc, CoTaskMemAlloc, NetApiBufferAllocate, VirtualAlloc, CryptMemAlloc, AllocADsMem, SHAlloc, SnmpUtilMemAlloc"
06:32 Will_the_Chill and I'm about to propagate to the other .t files
06:32 bulk88 test my changes on YOUR machine first
06:32 bulk88 they may work for me, IDK if they work for you
06:32 Will_the_Chill will wait on multi_sort.pl because it is not running for me, which means it probably won't run for you unless you roll back to github code from June
06:33 bulk88 if they worked for the world they would be in a github pull right now ;-)
06:33 Will_the_Chill yes I tested your changes
06:33 bulk88 getting pic of segv
06:34 bulk88 http://i43.tinypic.com/25pn1q0.png
06:34 Will_the_Chill okay, there now your changes to the 2 .t files are on github!
06:35 bulk88 I can't get to the original C code because it was deleted already
06:35 Will_the_Chill just do a grep for BULK88 in the latest github code and you'll see yourself
06:36 bulk88 I've once before debugging inline::C I have to find the option that stops it from deleting the intermediate products
06:36 bulk88 unless you can figure it out from the "Line" numbers in the C callstack
06:36 Will_the_Chill it should already be set to NOT delete the intermediate code?
06:36 Will_the_Chill look in the auto-generated _Inline directory?
06:37 bulk88 its empty, the dialog box shows it
06:37 mirjam joined #perl11
06:39 bulk88 http://pastebin.com/TAQLGTRd
06:39 Will_the_Chill my _Inline/ directory is full of files like /lib/auto/eval_442_0927/eval_442_0927.so
06:39 Will_the_Chill you don't have those files?
06:39 bulk88 .so == .dll
06:40 bulk88 .pdb is a MS symbol file
06:40 Will_the_Chill oh right
06:40 bulk88 .exp is DLL export table definition, plain text
06:40 bulk88 .lib == .a
06:41 bulk88 .inl IDK
06:42 bulk88 unlike in unix land with .so, on Win32, only symbols specifically marked for exporting get exposed between .dlls
06:43 Will_the_Chill Inline docs says it is supposed to stop itself from deleting the source files if there is a build error
06:43 bulk88 there isn't a build error, this is a runtime segv
06:43 bulk88 Farmer class I assume it something RPerl is writing
06:43 bulk88 *is
06:45 Will_the_Chill Farmer class is test code RPerl uses from the Inline cookbook
06:45 bulk88 I've had to do this before with Inline::C, I hate it, learn XS and how to write a real module
06:46 bulk88 99.999% of Win32 perls can NOT run a C compiler with system()
06:46 Will_the_Chill HAHA you so funny
06:46 bulk88 since we dont keep C compilers in %path since usually there are multiple C compilers
06:46 Will_the_Chill go ahead, write a Perl-to-XS compiler
06:46 Will_the_Chill :)
06:46 bulk88 each of them is an equal competitor
06:47 bulk88 there is no "system CC" notion on Win32, there is one in Perl, but not on the desktop
06:47 Will_the_Chill also, I had to un-commit your changes to the 2 .t files because it causes them to only work when run from within their own directory.  :(
06:47 bulk88 that is why I told you to test it
06:47 Will_the_Chill well I did test it but naively at first.  XD
06:48 Will_the_Chill then I remembered WHY I had hard-coded paths
06:48 bulk88 you can't hard code paths
06:48 Will_the_Chill yes I know I can't, thus my code comment "NEED REMOVE hard-coded paths"
06:48 bulk88 what if /tmp is /home/username/.tmp
06:48 Will_the_Chill and thus it being next on my to-do list, as mentioned
06:48 Will_the_Chill I can't tell you what my solution will be because I'm not working on it just yet
06:49 Will_the_Chill also, I understand your issue about Windows not being able to easily run a C compiler.  I could be snarky a-la your XS comment and say "learn Linux and how to run a real OS", but that would be SUPER RUDE!  ;)
06:50 Will_the_Chill honestly I have no idea how to get Windows to run a C compiler properly
06:50 Will_the_Chill cuz I don't have Windows
06:50 Will_the_Chill but I'm happy to accept any patches you have to address the issue!
06:51 Will_the_Chill in case it wasn't clear, Inline::C and Inline::CPP are the only reason something as awesome as RPerl can exist
06:52 Will_the_Chill the point is definitely NOT to create a Perl-to-XS compiler, that is only 1 of the possible uses of RPerl.
06:52 Will_the_Chill it is a very important use, but not the only one!
06:53 Will_the_Chill for example, using RPerl to compile to just-C-not-XS and having that run as a stand-alone executable
06:56 bulk88 Inline C AFAIK is XS
06:57 bulk88 its just a different set of I::C specific macros vs the XSPP macros
06:58 bulk88 http://perl5.git.perl.org/perl.git/blob/HEAD:/universal.c#l399 this is what "raw" XS looks like
06:59 bulk88 that is an XSUB written in pure C, AFAIK, Inline::C and (fact) XSPP both produce C functions which meet that ABI
07:00 bulk88 I'll start researching how to get the C/XS file for that crash now
07:01 Will_the_Chill uh, yeah, but you can feed C code through a C compiler and not care about Perl'ishness.
07:01 Will_the_Chill XS code is strongly linked to Perl
07:03 Will_the_Chill and generating Inline::C and Inline::CPP from low-magic Perl code is infinitely easier than generating the corresponding XS directly.  I'm sorry, but your argument is invalid.  :)
07:03 Will_the_Chill haha!
07:03 Will_the_Chill (all in good jest, my friend.)
07:04 Will_the_Chill I thought for sure I knew how to cause Inline to keep the source code without a crash
07:04 Will_the_Chill I guess not!
07:07 bulk88 if the C callstack says pp_entersub, you are using an XSUB/XS, if it goes from Perl_runops_standard() to something not core interp, then you have your own optree/opcodes
07:07 bulk88 those are the only 2 ways to integrate into P5
07:07 bulk88 well, there is also syscall() ;-)
07:08 bulk88 the C call stack in the pic isn't exactly true when its in perl519.dll frames
07:11 Will_the_Chill okay I generally understand, but not sure what is the point?
07:11 bulk88 figured out the SEGV
07:11 Will_the_Chill yay!
07:11 Will_the_Chill XS is like assembly to me, I should never EVER have to write a single line of XS code EVER.
07:12 Will_the_Chill if I am writing XS code then something is horribly wrong
07:12 Will_the_Chill This is why ingy created Inline in the first place.
07:13 bulk88 1 second explination "you need to turn off P5's hooking of C std lib"
07:13 bulk88 the longer explination/fix I need to research
07:14 Will_the_Chill nice short explanation, and I have no idea how to do that, haha!
07:15 bulk88 http://pastie.org/private/ucjaja6mxftyuudd89vvow
07:18 Will_the_Chill okay I see your Perl optree
07:18 Will_the_Chill not sure how to utilize that info?
07:18 bulk88 optree?
07:20 bulk88 it wasn't until dec 2012 until I changed the "XS module template" inside P5 to say PERL_NO_GET_CONTEXT, but it has been necessery for all "new code" since the late 1990s
07:20 bulk88 http://perl5.git.perl.org/perl.git/commit/3ee084aa8474e0a47583aee63a88beeea5d4742f?f=utils/h2xs.PL
07:20 bulk88 without PERL_NO_GET_CONTEXT macro, any perl.h using object files/binaries will be very slow
07:21 bulk88 since P5's headers turn on a "this C code is not ithreads aware mode"
07:21 bulk88 there is a 2nd macro that controls c std lib hooking
07:23 bulk88 http://perlmonks.org/?node_id=990724 dave_the_m is a p5p with commit bit
07:24 bulk88 that post/subthread eventually lead to me to add PERL_NO_GET_CONTEXT to the default XS module template
07:27 Will_the_Chill I know Dave Mitchell, he argues with me about RPerl stuff on PerlMonks.  :)
07:28 Will_the_Chill I mostly understand your PERL_NO_GET_CONTEXT comments, but again not sure how to utilize the info?
07:30 bulk88 all C/C++ code, WITHOUT EXCEPTION, must have "#define PERL_NO_GET_CONTEXT" before #include perl.h see https://github.com/bulk88/perl5-win32-api/blob/master/API.xs#L14
07:31 bulk88 NO_XSLOCKS turns off C std lib hooking
07:31 Will_the_Chill so you're telling me I should add "#define PERL_NO_GET_CONTEXT" to the C/C++ code that RPerl generates as output before it is fed through Inline:C and/or Inline::CPP?
07:31 Will_the_Chill and how do I utilize the NO_XSLOCKS thingy?
07:31 bulk88 no NO_XSLOCKS, means hook the C std lib, to *try* (it really doesn't work) and make thread unsafe C code thread safe
07:32 bulk88 the problem is, Inline::C hides the all of the real C code from you, so IDK
07:32 rurban1 joined #perl11
07:32 bulk88 that is why I use XSPP modules or raw C XSUBs
07:34 bulk88 see what perl does http://perl5.git.perl.org/perl.git/blob/HEAD:/XSUB.h#l434 ?
07:34 Will_the_Chill well I've already patched Inline::Filters, if we need to patch Inline::C and/or Inline::CPP then so be it!
07:35 Will_the_Chill I see the use of NO_XSLOCKS in the code you just sent, once again not sure how to utilize it?
07:37 bulk88 I dont use Inline::C, so I'd be reading the docs and/or googling just like you, ill do that in a coupel mins
07:38 mirjam joined #perl11
07:39 bulk88 http://mauke.hopto.org/stuff/perl/japh8.pl syscall is the 3rd way to escape Pure Perl inaddition to XSUBs and pp-* styled opcode/op struct functions
07:39 bulk88 +OT
07:44 Will_the_Chill what is +OT?
07:44 bulk88 Off topic
07:44 Will_the_Chill oh
07:44 Will_the_Chill haha okay
07:45 bulk88 http://www.perlmonks.org/?node_id=649074 :-) that was P5's "old" system
07:45 Will_the_Chill I went back and re-read the Inline::C docs and I could find was a thing that said it would save the source code in the _Inline build directory if there was a build error
07:46 bulk88 it allowed a decade of ABI compatibility with the penalty of 1 C macro that just derefs a struct being 15 functionc calls
07:46 bulk88 "C:\sources\rperl\t>perl -MInline=NOCLEAN 02_inline.t"
07:46 bulk88 thats what i did to get the C code to see the crash site
07:46 bulk88 eghh, not the crash site but what lead to it
07:47 Will_the_Chill I just found "CLEAN_AFTER_BUILD => 0,"
07:48 Will_the_Chill I wonder if that is the same switch as NOCLEAN?
07:49 bulk88 maybe :-p
07:49 bulk88 Inline has TIMTOADY to the max in its config instructions
07:49 Will_the_Chill okay YES
07:49 Will_the_Chill NOCLEAN is a shortcut to CLEAN_AFTER_BUILD => 0
07:50 bulk88 "config => {USE_FOO => 1}" or "config => {ENABLE => USE_FOO}"
07:50 Will_the_Chill exactly
07:50 Will_the_Chill sorry I forgot and we had to look it up.  :P
07:50 Will_the_Chill and sorry I missed it when I tried to look it up a few mins ago, haha!
07:52 bulk88 what I hate about google is, whenever I go googling for fixes for anything, my posts are always on the first screen for some reason, for example https://rt.cpan.org/Public/Bug/Display.html?id=84843
07:55 Will_the_Chill haha you should fix your own problems future-actively!
07:55 Will_the_Chill (that's the opposite of retroactively, FYI.)
07:55 Will_the_Chill boy, sundialsvc4 is a nut.  :)
07:58 bulk88 alternative voices are always good to have, even if they are a bit tinfoil-ish like sundialsvc4, i like to read his posts even though I dont think he has ever written code in his life, just a PHB who has coders working for him
07:59 bulk88 or he has a BS in Information Theory or Math, not CS
08:03 Will_the_Chill LOLphbdialsvc4
08:05 Will_the_Chill well he sure does provide a great representation of the knee-jerk half-baked pseud-criticisms of RPerl, which makes it possible (and even easy) for me to parry.
08:11 bulk88 I haven't read too deeply on your recent PM threads, but sundial, umm, I dont want to say he is smoking something, but he is a "fresh voice", and he does use Perl, code it, that is questionable, but he does use Perl
08:12 bulk88 I've found many of the things he says are from CS textbooks from >30 years ago
08:13 Will_the_Chill hmm interesting
08:13 Will_the_Chill maybe he is just  PHB as you say  :)
08:16 bulk88 I do like that Perlmonks has a PHB that posts regularly, otherwise the place would be boring with just a combination of basement hackers of questionable color hats, sys admins who code just enough to backup the server, offshore elance folks who never used Perl before, and Perl webdevs who will throw kilo-LOC OOP solutions at you
08:16 bulk88 plus a couple "I used to be a Perl programmer for a decade but now I'm the PHB" guys (BrowserUk)
08:17 bulk88 "and since my job description doesn't include any real work, I sit on Perlmonks all day helping random people all day long"
08:19 bulk88 and when I do start a thread on Perlmonks, it will take 1000 article publishers from Science 10 years to find a solution
08:21 bulk88 example http://perlmonks.org/?node_id=1059691
08:23 bulk88 http://perlmonks.org/?node_id=1046924
08:25 bulk88 generally on Perlmonks BrowserUk has a beef with sundial, but browseruk gave up on it or went anon, since browseruk often got downvotes for being combative/agressive with sundial from the PM community
08:26 bulk88 http://perlmonks.org/?node_id=1043486 another interesting thread from browserul
08:29 Will_the_Chill personally I like BrowserUK, in private he has been morally supportive of RPerl, but he did warn me that lots of people had beefs with him and I should be careful about associating with him publicly...
08:36 bulk88 IDK what to say, BUK seems old/experianced, and his knowledge scares me (bulk88), and he generally can outsmart most hardcore Perl programmers, he also has an ability to squeeze lots of performance out of pure perl code, which is also scary
08:37 bulk88 he doesn't exist outside of Perlmonks, and he has rarely gone to P5P but has a negative view on them, and refuses to cooperate with their "process"
08:38 bulk88 buk has made tickets on P5 RT once or twice
08:41 rurban1 joined #perl11
08:49 Will_the_Chill well he is a Pope on PerlMonks, so that means more than nothing
08:49 bulk88 http://pastie.org/private/x29bgovxqaxjeolxwbh7ba
08:50 bulk88 I can't figure out how to get the defines, either on command line, or in C code, into Inline::CPP, without editing ever single eval in 02_inline.t
08:50 bulk88 *every single
08:50 Will_the_Chill Inline::CPP must've broken the NOCLEAN shortcut
08:51 Will_the_Chill just use the CLEAN_AFTER_BUILD longcut
08:51 Will_the_Chill okay I'm totally assuming that Inline::CPP broke NOCLEAN, I have nothing more than your post to base that on, so perhaps I shouldn't have used the term "must've"  :)
08:52 bulk88 the error "It is invalid to use 'Inline::CPP' directly." comes from https://metacpan.org/source/SISYPHUS/Inline-0.53/Inline.pm#L91
09:01 bulk88 BEGIN { use lib '../lib/CPAN/';  use_ok('MyConfig'); }
09:01 bulk88 use Inline  (CPP => Config => CCFLAGS => '-DNO_XSLOCKS');
09:01 bulk88 diag("\n[[[ Beginning Selection Of Tests From The Inline::C Cookbook ]]]\n ");
09:01 bulk88 that doesn't syntax/perl compile time error
09:03 bulk88 and that C compile time failws
09:09 bulk88 http://pastie.org/private/c3yfigkue3qsqcebplev1g
09:10 bulk88 free to wrong pool after ok 25, is now C link error at at test 28
09:10 bulk88 progress
09:15 Will_the_Chill so this is all Windows-specific stuff I take it?
09:15 bulk88 no
09:16 bulk88 if your linux Perl, has ithreads, you will see the exact same SEGV I had earlier
09:16 bulk88 the link error now is win32/Visual C specific
09:16 bulk88 the segv in C++ destructor of Farmer class
09:16 bulk88 which was due to a lack of NO_XSLOCKS
09:17 Will_the_Chill "This is perl, v5.10.1 (*) built for i686-linux-gnu-thread-multi"
09:17 Will_the_Chill does that "thread-multi" mean something different than ithreads?
09:17 bulk88 thinking
09:17 Will_the_Chill IOW, how do I know if I have ithreads?
09:25 bulk88 I can't figure out what it is on Unix from reading the code, what is your -V for your "thread"ed perl?
09:25 bulk88 paste site it
09:30 Will_the_Chill http://pastebin.com/8t5DxXC3
09:30 Will_the_Chill useithreads=define
09:31 Will_the_Chill appears in -V
09:32 bulk88 "Free to wrong pool " is a Win32-only error message, on all threaded Win32 perls, you will NEVER see it on unix, Perl, rewrote the Win32 memory allocator sanity check, in pure C, as PERL_TRACK_MEMPOOL which will cause a "panic: free from wrong pool", note different spelling
09:33 bulk88 DEBUGGING AFAIK doesn't turn on PERL_TRACK_MEMPOOL, then again, im WIndows
09:33 bulk88 you on unix will never see NO_XSLOCKS since you dont have PERL_IMPLICIT_SYS on
09:34 bulk88 *never see any bugs from a lack of NO_XSLOCKS
09:36 Will_the_Chill okay so I know this is repetitive, but are you telling me that all the problems you've encountered so far are Windows-only?
09:39 bulk88 yes, because the OS (C std lib) virtualizer PERL_IMPLICIT_SYS isn't used on Unix (not sure if perl interp will compile with PERL_IMPLICIT_SYS on unix, ask in #p5p  ), so free() will never be hooked by perl in the first place, so XS_NOLOCKS makes no difference if free won't be hooked naturally
09:40 bulk88 one of PERL_IMPLICIT_SYS's purposes is so 2 different psuedo-forks on Windows can have 2 different shell envs
09:41 bulk88 2 different %ENVs in the same process
09:41 bulk88 it does alot of other virtuallization, with many holes in its implementation
09:41 bulk88 1 arg select() is process global, not psuedoprocess global on windows for example
09:42 bulk88 until you release RPerl as a cpan module and the CPANTesters Win32 smokers try to build it, you wont see it on unix
09:42 bulk88 unless you want to try Win32 Perl on Wine on Linux
09:44 Will_the_Chill how is that any different than what you're doing now by just running it on your Windows box?
09:45 bulk88 Win32 Perl has an OS virutallizer in it, written and maintained by P5P/ActiveState
09:46 rurban1 joined #perl11
09:48 Will_the_Chill okay.  but still, how is Win32 smokers any different than you running it on your Windows box?
09:48 bulk88 think Wine or Cygwin or ndiswrapper
09:48 Will_the_Chill sure, I'm familiar with those 3 programs.
09:48 bulk88 but Win32 Perl's os viruallizer is 25% of Wine or Cygwin in feature set, the other 75% of the features are bug tickets that will never be fixed
09:49 bulk88 the Win32 smokers will fail the same way RPerl did on my machine
09:50 Will_the_Chill okay so then why do you say I have to "wait for the Win32 smokers" when you're doing the same thing right now?
09:53 bulk88 if I'm hit by a bus tomorrow and can't test your code, and you have no access to a Windows machine yourself, then CPANTesters and AS PPM ( http://code.activestate.com/ppm/File-Temp/ click one of the green check marks, then click "view build log") are the only way to test RPerl on windows
09:53 bulk88 *are the only way __for you__ to test
09:54 bulk88 the interesting thing to note aboute CPANTesters vs AS PPM is, all Win32 CPANTesters smokers are GCC, zero Visual Cs, the AS PPM smoker is Visual C
09:55 * bulk88 walks away whistling
09:55 bulk88 anyway
09:56 bulk88 so a Win32 GCC smoker, can succeed, where a Win32 Visual C smoker failed
10:00 Will_the_Chill huh
10:00 bulk88 another problem is, I often find *nix Perl/XS/C code is written with GCC C Extensions code, so even a C99 but not GCC compatible compiler (clang, ICL on Linux) wont work/syntax errors
10:00 Will_the_Chill once I upload to CPAN does it automatically get tested?
10:01 Will_the_Chill I need C++11 for RPerl
10:01 bulk88 if "Makefile.pl" and then "make test" works, yes
10:01 Will_the_Chill and I need clang to work
10:03 bulk88 clang pretends it is a GCC, so clang takes almost all "proprietary GCC extensions to ISO C of any year"
10:06 bulk88 HPUX, Sun, and AIX have their own non-GCC compilers also I think
10:06 Will_the_Chill C++11 is for current use, clang is for future use
10:06 Will_the_Chill glad to hear they are both acceptable.  :)
10:09 bulk88 http://gcc.gnu.org/onlinedocs/gcc/Statement-Exprs.html#Statement-Exprs this is not C89, C99, or C11
10:09 bulk88 that is the number 1 GCC-specific feature I run into
10:11 Will_the_Chill why does GCC have features not found in standard C/C++?
10:15 bulk88 ask the authors of GCC
10:15 Will_the_Chill Well I sure as heck don't plan to use any non-ISO features!
10:15 Will_the_Chill that would just be SILLY!  :)
10:19 bulk88 http://gcc.gnu.org/onlinedocs/gcc/C-Implementation.html#C-Implementation  http://gcc.gnu.org/onlinedocs/gcc/C_002b_002b-Implementation.html#C_002b_002b-Implementation http://gcc.gnu.org/onlinedocs/gcc/C-Extensions.html#C-Extensions  http://gcc.gnu.org/onlinedocs/gcc/C_002b_002b-Extensions.html#C_002b_002b-Extensions  if you want a long read or you have OCD, it doesn't hurt to read through those
10:19 bulk88 things, I've read the Visual C equivelents at one point
10:21 Will_the_Chill ouch, maybe it _does_ hurt to read through those.  ;)
10:22 bulk88 you probably should start by reading all the federal laws that can get you in trouble first http://extent-of-regulation.dhwritings.com/ :-p
10:23 bulk88 CFR, it runs your life
10:23 bulk88 I find reading ISO C (the actual standard), and compiler manuals, is very similar to reading CFR
10:26 Will_the_Chill complicated laws are complicated
10:27 Will_the_Chill complicated standards are complicated
10:27 Will_the_Chill :)
10:30 bulk88 im still working on the linking error Inline::CPP doesn't know what .lib/.a is C++ std lib  out of the box
10:31 Will_the_Chill roger that
10:32 Will_the_Chill I'm working on business stuff to court possible RPerl investors.  :)
10:32 Will_the_Chill it sure would be nice to have a sponsor and hire a bunch of programmers!
10:36 bulk88 success (for me) http://pastie.org/private/0gt9ko6kitkwkm886eoxaa
10:39 Will_the_Chill cool beans!
10:39 Will_the_Chill what's that 1 failed test about?
10:39 Will_the_Chill and what did you have to do to achieve this miracle?  :)
10:41 bulk88 Inline::CPP, during the installation asks what LIBC you want to use, the defaulted offered to me was "MSVCIRT.LIB", that is wrong, I then tried "MSVCRT.LIB" (C std lib, which has some mangled C++ symbols in it for "C++ lite" (my term)), that didn't work, then I tried "MSVCPRT.LIB", MSVCIRT.LIB is called "Old Iostream", MSVCPRT.LIB is called "Standard C++" , MS's long explination I dont understand
10:41 bulk88 http://msdn.microsoft.com/en-us/library/aa272081%28v=vs.60%29.aspx
10:42 bulk88 http://msdn.microsoft.com/en-us/library/8h8eh904%28v=vs.90%29.aspx more explination I dont understand
10:45 bulk88 http://www.nntp.perl.org/group/perl.inline/2012/08/msg4317.html I'm not the only one, but that thread was in a very low reply list
10:49 Will_the_Chill can you please write basic directions in the install doc?  terse is fine, as you already know.  :)
10:54 rurban1 joined #perl11
10:54 bulk88 changes so far http://pastie.org/private/2zyoat4ja4xtw3tvypnw
10:54 bulk88 other than Inline::CPP what .lib is cpp std lib, and the patch to git Rperl so far, that are the instructions
10:55 bulk88 *those
10:58 Will_the_Chill CCFLAGSEX  poor choice of variable name
10:58 Will_the_Chill XD
10:59 Will_the_Chill so which std lib worked?
11:00 bulk88 MSVCPRT.LIB, not Inline::CPP's MSVCIRT.LIB, the choice was set (by me) when Inline::CPP was built/installed
11:00 bulk88 IDK if its one-off settable or not, IDC ATM
11:00 bulk88 Inline::CPP's default of MSVCIRT.LIB
11:06 Will_the_Chill gotcha
11:08 bulk88 in Airplane/Object class, I see method nonprint, and var "ostringstream oretval;", then I see "oretval << "Object (" << this << ")";", did you ever "initialize" var oretval?
11:09 bulk88 I dont know C++, so IDK what "initialize" is in C++ for stack/auto vars
11:11 Will_the_Chill I did not write that code, I copied/pasted it from the Inline::CPP docs.
11:12 Will_the_Chill are you getting a "not initialized" error or something?
11:14 bulk88 on test 30, the start of the string is binary giberish (maybe intentional? IDK, looks like uninit mem to me, the C guy), and later the "Object" string is gone, and the 0x from the this pointer in hex is gone
11:15 bulk88 http://pastie.org/private/0gt9ko6kitkwkm886eoxaa test 30 fails
11:26 Will_the_Chill '/Object\ \(0x\w*\)/' is a match pattern for what Perl objects references look like in Linux
11:26 Will_the_Chill like this:
11:27 Will_the_Chill Object (0x5AC4883BE)
11:27 Will_the_Chill (I just made up that address)
11:27 Will_the_Chill your Windows object seems to be a different format?
11:31 bulk88 "is a match pattern for what Perl objects references look like in Linux" ????
11:31 bulk88 C:\sources\rperl\t>perl -e "print \$foo"
11:31 bulk88 SCALAR(0x8fc92c)
11:34 bulk88 memory dump of the char * "0x01112398  c0 54 0c 01 63 74 20 28 30 31 34 33 37 37 41 38 29 00 b7 01 00 00 00 00 00 00 00 00 ac  Ã€T..ct (014377A8).·.........¬"
11:38 Will_the_Chill yes it is just like the SCALAR(0xFOO) format
11:41 Will_the_Chill okay wait no I'm wrong
11:41 Will_the_Chill that's what a C++ object looks like, NOT a Perl object, sorry!
11:41 Will_the_Chill Perl object is like this
11:41 Will_the_Chill MyClass=HASH(0x81e6818)
11:42 Will_the_Chill when blessed hash ref used as object
11:42 Will_the_Chill oops, my bad!
11:42 Will_the_Chill I guess Windows has a different representation of C++ objects than Linux?
11:42 bulk88 you do realize "SCALAR(0x8fc92c)" is implemented in Perl 5's C code, in the "2pv_flags" code, it isn't C++
11:43 bulk88 I wouldn't even know where to look to figure out what a C++ object/this pointer casts/converts to for ostringstream object
11:43 bulk88 << is binary shift operator, not IO in C
11:47 bulk88 http://msdn.microsoft.com/en-us/library/6kacs5y3%28v=vs.71%29.aspx  http://msdn.microsoft.com/en-us/library/ba4ae8wb%28v=vs.71%29.aspx
11:47 Will_the_Chill okay I'm totally stupid, "oretval << "Object (" << this << ")"; is where the Object(0xfoo) format comes from
11:48 Will_the_Chill I don't know how that is occuring.
11:48 Will_the_Chill perhaps due to the lack of oretval initialization as you point out?
11:48 bulk88 http://pastie.org/private/0pifvzl9ujzrl1g4dbbvg
11:48 Will_the_Chill like I said, I didn't write that code, it was presumably from Neil Watkiss who wrote Inline::CPP
11:49 bulk88 i dont know C++, I can only guess by what Perl and JS OOP things do
11:50 Will_the_Chill 03...t works for me
11:50 Will_the_Chill http://pastebin.com/W1CNYAuF
11:51 bulk88 after removing "open(STDOUT, ">/dev/null") || die "Can't redirect stdout";  ## no critic" and STDERR version I get hold on
11:52 bulk88 http://pastie.org/private/hwrzpgw9uyxzcj79ucq8w
11:55 bulk88 http://pastie.org/private/vpdk8rglln4ir0hmfqe2g this is somewhere inside RPerl I think
11:56 Will_the_Chill yeah I redirected STDOUT to suppress seemingly-useless warnings during build time
11:56 bulk88 the "'CCFLAGS' => ' -Wno-deprecated -std=c++0x'," looks like it came from RPerl
11:56 bulk88 somewhere
11:57 Will_the_Chill that last pastie you sent me with the makefile.pl is not RPerl itself, it is the output of Inline
11:57 Will_the_Chill it is not code I've ever seen before
11:57 Will_the_Chill I haven't done anything with MakeMaker myself on RPerl yet
11:58 Will_the_Chill OH YEAH you mean just the CCFLAGS
11:58 Will_the_Chill yes those CCFLAGS came from RPerl
11:58 Will_the_Chill same CCFLAGS used to compile all RPerl-generated code
11:58 Will_the_Chill another example of some Windows equivalent option that I don't know?
11:58 Will_the_Chill brb
12:01 bulk88 http://pastie.org/private/gevwmshoimk2ybnwgnlwnq
12:04 bulk88 -Wno-deprecated that is a warning, its MSVC equivelent and how to silence it is irrelvelent,  "-std=c++0x" no equivelent, Inline::CPP already uses -TP which means compile as "C++" not "C"
12:13 bulk88 i'll probably leave soon, if I dont respond in 1-3 mins, it means im gone
12:18 Will_the_Chill roger
12:19 Will_the_Chill so does it work?
12:20 Will_the_Chill I looked at the last pastie, the occurrences of those CCFLAGS in ./lib/RPerl/* are mine; the occurrences of CCFLAGS in ./t/_Inline/build/* are from Inline, presumably derived from the same in RPerl
12:21 bulk88 yep
12:21 bulk88 so what happens to the CCFLAGS in RPerl?
12:22 Will_the_Chill right now the CCFLAGS are just hard-coded into RPerl
12:22 Will_the_Chill I'm not sure what you mean by "what happens to"?
12:22 Will_the_Chill the hard-coded CCFLAGS are passed verbatim to Inline, which does stuff with them and then (presumably) passes them to the C/C++ compiler.
12:24 rurban1 joined #perl11
12:25 Will_the_Chill so show me your successful output of 03...t?
12:25 bulk88 I deleted all the CCFLAGS from RPerl, now NO_XSLOCKS is back http://pastie.org/private/pp8jj1vvz8sr531bo898a
12:26 Will_the_Chill oh dang
12:29 bulk88 after NO_XSLOCKS fix http://pastie.org/private/czu48r6bvageoy9f7mjsq #include unordered_map is now a problem, I'm guessing VC 2003 doesn't have C++11 support, my VC 2008 does have a file called unordered_map, but I'm not at my VC 2008 machine
12:31 Will_the_Chill right
12:32 Will_the_Chill unordered_map is new to me as well, just now learning it for use in RPerl
12:32 Will_the_Chill unordered_map is the same as associative array AKA hash
12:34 bulk88 I don't have a fix for that, unless I'll copy unordered_map from vc08 to vc03, and then I'll probably hit more problems I cant fix
12:35 bulk88 i think i'm done for today, i need to get to my vc08 machine, and its not near me
12:35 Will_the_Chill *nods head*
12:35 Will_the_Chill well that was awesome, thanks for hacking with me.  :)
14:30 rurban1 joined #perl11
14:50 bluescreen joined #perl11
15:25 mirjam joined #perl11
15:57 rurban1 joined #perl11
17:22 mirjam left #perl11
20:21 stevan joined #perl11
21:35 bluescreen joined #perl11
21:35 bluescreen joined #perl11
22:55 bulk88 note to archaeologists, every paste I put here in last 24 hours will expire in a month, dont expect the links to work

| Channels | #perl11 index | Today | | Search | Google Search | Plain-Text | summary