Author: Whiteknight
Date: Tue Aug 19 14:08:02 2008
New Revision: 30354
Modified:
branches/gsoc_pdd09/NEWS
branches/gsoc_pdd09/PLATFORMS
branches/gsoc_pdd09/compilers/pct/src/PAST/Compiler.pir
branches/gsoc_pdd09/docs/pdds/pdd09_gc.pod
branches/gsoc_pdd09/languages/abc/src/ (props changed)
branches/gsoc_pdd09/languages/lua/src/lua51.pir
branches/gsoc_pdd09/languages/perl6/docs/spectest-progress.csv
branches/gsoc_pdd09/languages/perl6/src/parser/actions.pm
branches/gsoc_pdd09/languages/perl6/t/spectest_regression.data
branches/gsoc_pdd09/languages/t/harness
branches/gsoc_pdd09/languages/tcl/src/ops/tcl.ops
branches/gsoc_pdd09/ports/debian/changelog
branches/gsoc_pdd09/ports/debian/control.in
branches/gsoc_pdd09/ports/debian/copyright
branches/gsoc_pdd09/ports/debian/libparrot-dev.install
branches/gsoc_pdd09/ports/debian/parrot-doc.docs
branches/gsoc_pdd09/ports/debian/parrot.docs
branches/gsoc_pdd09/ports/debian/parrot.install
branches/gsoc_pdd09/ports/debian/rules
branches/gsoc_pdd09/src/debug.c
branches/gsoc_pdd09/src/inter_call.c
branches/gsoc_pdd09/src/interpreter.c
branches/gsoc_pdd09/src/library.c
branches/gsoc_pdd09/src/parrot_debugger.c
Log:
[gsoc_pdd09] update to trunk from r30310
Modified: branches/gsoc_pdd09/NEWS
==============================================================================
--- branches/gsoc_pdd09/NEWS (original)
+++ branches/gsoc_pdd09/NEWS Tue Aug 19 14:08:02 2008
@@ -9,23 +9,32 @@
+ PDD27: add multisub lookup
- Languages
+ Cardinal (Ruby):
+ - Class variables
+ - Parsing improvements
+ - Minor additions to class builtins
+ - Add support for block parameters to functions
+ Lua:
- various language fixes
- refactor all libraries (namespace, method registration)
- add a OpenGL binding (still incomplete)
+ - lost user back trace (see ppd25 & pushaction)
+ Pipp (PHP):
- Add support for while- and for-loops
- Add support for increment and decrement
- - Designate PHP 5.3 as the reference implementation
+ - Designate PHP 5.3 as the reference implementation
- Improve support for string literals
+ Pugs (Perl 6):
- removed due to bit rot
+ Rakudo (Perl 6):
+ - now over 2200 passing spectests
- updated the Rakudo roadmap
- Perl 6 multi dispatch
- dispatch with slurpies
- class attributes ("my $.x")
- - now up to 2196 passing tests
+ - anonymous classes
+ - OO and metaclass improvements (.WHAT, .WHICH, .WHENCE)
+ - additional builtin methods and subs
+ - improved make test targets and harness
+ Tcl:
- implement [lreverse], [lsort -command]
- allow [incr] to autovivify
@@ -35,6 +44,9 @@
- Compilers
+ PCT:
- :scope('register') for PAST::Var nodes
+ - allow invocant specification in attribute scope PAST::Var nodes
+ - correct ordering of sub generation from POST
+ - add 'loadinit' attribute to PAST::Block for block initialization
+ PIRC:
- PIR registers now use the vanilla register allocator
- all PASM output now uses PASM registers
Modified: branches/gsoc_pdd09/PLATFORMS
==============================================================================
--- branches/gsoc_pdd09/PLATFORMS (original)
+++ branches/gsoc_pdd09/PLATFORMS Tue Aug 19 14:08:02 2008
@@ -35,8 +35,8 @@
linux-x86_64-gcc4.1.0 4 Y - - Y Y Y Y/2 ?
20060807
linux-x86_64-gcc4.1.2 8 Y - - Y Y Y Y ?
20080220
openbsd-zaurus-gcc3.3.5 Y - - Y Y Y ? ?
20070309
-sol8-sparc-cc B - - - - - - Y/1 ?
20080401
-sol8-sparc-gcc_4.1.0 B - - - - - - Y/77 ?
20080401
+sol8-sparc-cc B - - - - - - Y/85 ?
20080818
+sol8-sparc-gcc_4.1.0 B - - - - - - Y/87 ?
20080818
sol10-sparc-cc_5.8 B Y - - Y Y Y Y/9 ?
20060807
sol10-sparc-cc_5.9 B4*4 Y - - Y Y Y Y ?
20080510
sol10-sparc-cc_5.9 B8 Y - - Y Y Y Y/2 ?
20080518
@@ -48,7 +48,7 @@
tru64-alpha-compaq_c6.5 8 ? ? ? Y ? Y Y/2 ?
20060203
cygwin1.5.24-x86-gcc3.4.4 4 Y Y - - - Y Y/6*1 ?
20071016
cygwin1.5.25-x86-gcc3.4.4 4 Y Y - - - Y Y/6*1 ?
20080513
-win32-x86-mingw_gcc3.4.5 Y Y - - - Y Y/2 Y
20080617
+win32-x86-mingw_gcc3.4.5 Y Y - - - Y Y/1 Y
20080819
win32-x86-mingw_gcc4.2.1 Y Y - - - Y Y/11 ?
20080520
win32-x86-msvc_6.0 - Y - Y - Y Y/5 ?
20080520
win32-x86-msvc_7.1 - Y - Y - Y Y/11 ?
20080520
Modified: branches/gsoc_pdd09/compilers/pct/src/PAST/Compiler.pir
==============================================================================
--- branches/gsoc_pdd09/compilers/pct/src/PAST/Compiler.pir (original)
+++ branches/gsoc_pdd09/compilers/pct/src/PAST/Compiler.pir Tue Aug 19
14:08:02 2008
@@ -518,21 +518,27 @@
blockpast = get_global '@?BLOCK'
unshift blockpast, node
- .local string name
+ .local string name, pirflags, blocktype
+ .local pmc ns
name = node.'name'()
+ pirflags = node.'pirflags'()
+ blocktype = node.'blocktype'()
+ ns = node.'namespace'()
+
+ ## handle anonymous blocks
if name goto have_name
name = self.'unique'('_block')
+ if ns goto have_name
+ pirflags = concat pirflags, ' :anon'
have_name:
## create a POST::Sub node for this block
- .local string blocktype
- blocktype = node.'blocktype'()
- .local pmc ns, pirflags
- ns = node.'namespace'()
- pirflags = node.'pirflags'()
.local pmc bpost
$P0 = get_hll_global ['POST'], 'Sub'
- bpost = $P0.'new'('node'=>node, 'name'=>name, 'blocktype'=>blocktype,
'namespace'=>ns, 'pirflags'=>pirflags)
+ bpost = $P0.'new'('node'=>node, 'name'=>name, 'blocktype'=>blocktype,
'namespace'=>ns)
+ unless pirflags goto pirflags_done
+ bpost.'pirflags'(pirflags)
+ pirflags_done:
## determine the outer POST::Sub for the new one
.local pmc outerpost
@@ -672,7 +678,10 @@
$P0 = get_hll_global ['POST'], 'Ops'
bpost = $P0.'new'(bpost, 'node'=>node, 'result'=>result)
if ns goto block_decl_ns
- bpost.'push_pirop'('get_global', result, name)
+ concat $S0, '.const .Sub ', result
+ concat $S0, ' = '
+ concat $S0, name
+ bpost.'push_pirop'($S0)
goto block_done
block_decl_ns:
bpost.'push_pirop'('get_hll_global', result, ns, name)
Modified: branches/gsoc_pdd09/docs/pdds/pdd09_gc.pod
==============================================================================
--- branches/gsoc_pdd09/docs/pdds/pdd09_gc.pod (original)
+++ branches/gsoc_pdd09/docs/pdds/pdd09_gc.pod Tue Aug 19 14:08:02 2008
@@ -377,7 +377,7 @@
Trigger or perform a GC run. With an incremental GC core, this may only
start/continue a partial mark phase or sweep phase, rather than performing an
entire run from start to finish. It may take several calls to C<do_gc_mark> in
-order to complete an entire incremental run.
+order to complete an entire run of an incremental collector.
For a concurrent collector, calls to this function may activate a concurrent
collection thread or, if such a thread is already running, do nothing at all.
@@ -432,17 +432,20 @@
=item C<void (*finalize_gc_system) (Interp *)>
Called during interpreter destruction. Free used resources and memory pools.
+All PMCs must be swept, and PMCs with custom destroy VTABLE methods must have
+those called.
=item C<void (*init_pool) (Interp *, Small_Object_Pool *)>
-Initialize the given pool. This function should set the following function
-pointers for use with the pool.
+Initialize the given pool. Populates the C<Small_Object_Pool> structure with
+initial values, and sets a series of function pointers for working with the
+pool. The function pointers used with the pool are discussed next.
=back
=head3 Small_Object_Pool function pointers
-Each GC core defines 4 function pointers stored in the Small_Object_Pool
+Each GC core defines 4 function pointers stored in the C<Small_Object_Pool>
structures. These function pointers are used throughout Parrot to implement
basic behaviors for the pool.
@@ -458,7 +461,10 @@
=item C<void (*add_free_object) (Interp *, Small_Object_Pool *, PObj *);>
-Add a freed object to the pool's free list.
+Add a freed object to the pool's free list. This function is most often called
+internally to the GC itself to add items to the free list after a sweep, or
+when a new arena is created to add the new items to the free list. It does
+not need to be used in this way, however.
=item C<void (*alloc_objects) (Interp *, Small_Object_Pool *);>
@@ -471,93 +477,104 @@
Reallocation for additional objects. It has the same signature as
C<alloc_objects>, and in some GC cores the same function pointer is used for
both. In some GC cores, C<more_objects> may do a GC run in an attempt to free
-existing objects without having to allocate new ones.
+existing objects without having to allocate new ones. This function may also
+call C<pool->alloc_objects> internally, to allocate objects if a GC run fails
+to free any old objects.
=back
=head3 Write Barrier
-Each GC core has to provide these (possibly empty) macros:
+Each GC core has to provide the following macros. All of these might be
+defined empty, for GC cores which do not use them.
=over 4
=item C<GC_WRITE_BARRIER(Interp *, PMC *agg, PMC *old, PMC *new)>
This macro is invoked when in aggregate C<agg> the element C<old> is getting
-overritten by C<new>. Both C<old> and C<new> may be NULL.
+overwritten by C<new>. Either C<old>, C<new>, or both may be NULL.
=item C<GC_WRITE_BARRIER_KEY(Interp *, PMC *agg, PMC *old, PObj
*old_key, PMC *new, PObj *new_key)>
-Like above. Invoked when a hash key is inserted, possibly replacing an old
-key.
+Similar to C<GC_WRITE_BARRIER>. Invoked when a hash key C<new_key> is
+inserted into hash C<agg> with value C<new>, possibly replacing a key/value
+pair C<old_key> and C<old>, respectively. Any of C<old>, C<old_key>, C<new>
+or C<new_key> might be C<NULL>.
=back
=head2 Blocking GC
Being able to block GC is important, so newly allocated Buffers or PMCs won't
-be collected before they're attached to the live tree. The following
-routines control GC:
+be collected before they're attached to the live tree. Parrot provides locking
+mechanisms to prevent the GC from taking certain actions, such as marking
+or sweeping. GC block functions are nesting, and multiple calls to a lock
+function requires the same number of calls to the corresponding unlock
+function in order to operate the GC normally again. The following functions
+are used to block the GC from performing certain actions:
=over 4
=item Parrot_block_GC_mark(Interp *interpreter)
-Block the GC mark phase for the passed interpreter. (But not the sweep phase)
+Block the GC mark phase for the passed interpreter, but do not block the sweep
+phase. In a stop-the-world collector, this will prevent the entire collection
+run, but in an incremental collector this will only block if the GC is in the
+trace state.
=item Parrot_block_GC_sweep(Interp *interpreter)
-Block the GC sweep phase for the passed interpreter. (But not the mark phase)
+Block the GC sweep phase for the passed interpreter, but do not block the
+trace phase.
=item Parrot_unblock_GC_mark(Interp *interpreter)
-Unblock the GC mark phase for the passed interpreter. (But not the sweep
-phase)
+Unblock the GC mark phase for the passed interpreter, but do not unblock a
+blocked sweep phase, if it is blocked using C<Parrot_block_GC_sweep>.
=item Parrot_unblock_GC_sweep(Interp *interpreter)
-Unblock the GC sweep phase for the passed interpreter. (But not the mark
-phase)
+Unblock the GC sweep phase for the passed interpreter, but do not unblock the
+mark phase if it has been blocked by C<Parrot_block_GC_mark>.
=item Parrot_is_blocked_GC_mark(Interp *interpreter)
-Test whether the mark phase has been blocked.
+Test whether the mark phase has been blocked. Notice that the sweep phase can
+be locked independently and cannot be determined using this function.
=item Parrot_is_blocked_GC_sweep(Interp *interpreter)
-Test whether the sweep phase has been blocked.
+Test whether the sweep phase has been blocked. Notice that the mark phase can
+be locked independently and cannot be determined using this function.
=back
-Note that the blocking is recursive--if you call Parrot_block_GC_sweep() three
-times in succession, you need to call Parrot_unblock_GC_sweep() three times to
-re-enable the GC sweep phase.
-
=head2 PMC/Buffer API
=head3 Flags
For PMCs and Buffers to be collected properly, you must set the appropriate
-flags on them.
-
-Directly manipulating these flags is not recommended. Always use the macros
-defined in F<include/parrot/pobj.h>.
+flags on them. Directly manipulating these flags is not recommended because
+the exact values can be changed over time. A series of macros have been created
+in F<include/parrot/pobject.h> that set and check for these flags. Always use
+these provided macros when you need to test or set these flags.
=over 4
=item PObj_active_destroy_FLAG
The PMC has some sort of active destructor, and will have that destructor
-called when the PMC is destroyed.
+called when the PMC is destroyed. The destructor is typically called from
+within C<src/gc/dod.c:Parrot_dod_free_pmc>.
=item PObj_custom_mark_FLAG
The C<mark> vtable slot will be called during the GC mark phase. The mark
function must call C<pobject_lives> for all non-NULL objects (Buffers and
-PMCs) that PMC refers to.
-
-Please note that C<pobject_lives> may be a macro.
+PMCs) that PMC refers to. This flag is typically tested and the custom mark
+VTABLE method called from C<src/gc/dod.c:mark_special>.
=item PObj_data_is_PMC_array_FLAG
@@ -587,7 +604,9 @@
=item PObj_live_FLAG
-The system considers the object to be alive for collection purposes.
+The system considers the object to be alive for collection purposes. Objects
+with this flag set should never be collected, freed, destroyed, or put on the
+free list.
=item PObj_on_free_list_FLAG
Modified: branches/gsoc_pdd09/languages/lua/src/lua51.pir
==============================================================================
--- branches/gsoc_pdd09/languages/lua/src/lua51.pir (original)
+++ branches/gsoc_pdd09/languages/lua/src/lua51.pir Tue Aug 19 14:08:02 2008
@@ -198,15 +198,20 @@
.sub 'pir' :method :multi(_, ['Lua::POST::Chunk'])
.param pmc node
+ .local pmc subcode
+ subcode = get_global '@!subcode'
+ $P0 = new 'CodeString'
+ push subcode, $P0
.local pmc code
code = self.'pir_children'(node)
$S0 = node.'prologue'()
if $S0 == '' goto L1
new code, 'CodeString'
code.'emit'($S0)
- $P0 = self.'code'()
+ $P0 = pop subcode
code .= $P0
- self.'code'(code)
+ $P0 = subcode[-1]
+ $P0 .= code
L1:
.return (code)
.end
Modified: branches/gsoc_pdd09/languages/perl6/docs/spectest-progress.csv
==============================================================================
--- branches/gsoc_pdd09/languages/perl6/docs/spectest-progress.csv
(original)
+++ branches/gsoc_pdd09/languages/perl6/docs/spectest-progress.csv Tue Aug
19 14:08:02 2008
@@ -88,3 +88,4 @@
"2008-08-16 00:00",30256,121,3268,2220,0,134,914,6138
"2008-08-17 00:00",30275,121,3268,2220,0,134,914,6170
"2008-08-18 00:00",30292,121,3268,2220,0,134,914,6170
+"2008-08-19 00:00",30322,121,3268,2220,0,134,914,6242
Modified: branches/gsoc_pdd09/languages/perl6/src/parser/actions.pm
==============================================================================
--- branches/gsoc_pdd09/languages/perl6/src/parser/actions.pm (original)
+++ branches/gsoc_pdd09/languages/perl6/src/parser/actions.pm Tue Aug 19
14:08:02 2008
@@ -29,6 +29,23 @@
# Make sure we have the interpinfo constants.
$past.unshift( PAST::Op.new( :inline('.include "interpinfo.pasm"') ) );
+ # convert the last operation of the block into a .return op
+ # so that :load block below isn't used as return value
+ $past.push( PAST::Op.new( $past.pop(), :pirop('return') ) );
+ # automatically invoke mainline on :load (but not :init)
+ $past.push(
+ PAST::Block.new(
+ PAST::Op.new(
+ :inline(
+ '$P0 = interpinfo .INTERPINFO_CURRENT_SUB',
+ '$P0 = $P0."get_outer"()',
+ '$P0()'
+ )
+ ),
+ :pirflags(':load')
+ )
+ );
+
make $past;
}
@@ -1332,6 +1349,7 @@
$past.unshift(PAST::Var.new(
:name('$_'),
:scope('lexical'),
+ :viviself('Failure'),
:node($/)
));
}
Modified: branches/gsoc_pdd09/languages/perl6/t/spectest_regression.data
==============================================================================
--- branches/gsoc_pdd09/languages/perl6/t/spectest_regression.data
(original)
+++ branches/gsoc_pdd09/languages/perl6/t/spectest_regression.data Tue Aug
19 14:08:02 2008
@@ -7,10 +7,12 @@
S02-builtin_data_types/array.t
S02-builtin_data_types/flattening.t
S02-builtin_data_types/hash.t
+S02-builtin_data_types/hash_ref.t
S02-builtin_data_types/nested_arrays.t
S02-builtin_data_types/nested_pairs.t
S02-builtin_data_types/num.t
S02-builtin_data_types/range.t
+S02-builtin_data_types/subscripts_and_context.t
S02-builtin_data_types/type.t
S02-literals/autoref.t
S02-literals/hex_chars.t
Modified: branches/gsoc_pdd09/languages/t/harness
==============================================================================
--- branches/gsoc_pdd09/languages/t/harness (original)
+++ branches/gsoc_pdd09/languages/t/harness Tue Aug 19 14:08:02 2008
@@ -46,7 +46,7 @@
=item Run a single test for more detailed output.
- cd languages/tcl && prove t/joe_test.t
+ cd languages/tcl && prove -v t/cmd_lsort.t
=back
@@ -79,12 +79,10 @@
# ecmascript No t/harness
# eclectus
# forth No t/harness
-# lua many test failures
# perl6 test scripts are written in Perl 6, not Perl 5
# pheme test scripts are written in Scheme, not Perl 5
# PIR many test failures
# pynie test scripts are written in PIR, not Perl 5
-# python not maintained
# scheme many test failures
# urm uses deprecated parrot features
# Zcode Method 'instantiate' not found for 'Zmachine'
@@ -99,7 +97,7 @@
dotnet
hq9plus
jako
- lazy-k lisp
+ lazy-k lisp lua
m4
ook
parrot_compiler pipp punie
@@ -114,6 +112,8 @@
@unified_testable_languages;
# Step 2: Get a listing of files from these harnesses.
+#
+# See L<Parrot::Test::Harness> for information regarding --master.
my @tests;
foreach my $harness (@harnesses) {
Modified: branches/gsoc_pdd09/languages/tcl/src/ops/tcl.ops
==============================================================================
--- branches/gsoc_pdd09/languages/tcl/src/ops/tcl.ops (original)
+++ branches/gsoc_pdd09/languages/tcl/src/ops/tcl.ops Tue Aug 19 14:08:02 2008
@@ -3,10 +3,6 @@
* Copyright (C) 2006-2008, The Perl Foundation.
*/
-/*
-** tcl.ops
-*/
-
#include "parrot/parrot.h"
#include "parrot/string_funcs.h"
#include "parrot/exceptions.h"
@@ -24,7 +20,7 @@
=head1 DESCRIPTION
A dynamic opcode library for tcl on parrot that provides a few opcodes
-that simplify PIR generation for tclPIR generation for tcl
+that simplify PIR generation for tcl.
BUGS: pull out the TCL_ constants, as well as the code slot(#9)
Modified: branches/gsoc_pdd09/ports/debian/changelog
==============================================================================
--- branches/gsoc_pdd09/ports/debian/changelog (original)
+++ branches/gsoc_pdd09/ports/debian/changelog Tue Aug 19 14:08:02 2008
@@ -1,3 +1,13 @@
+parrot (0.6.4-1) unstable; urgency=low
+
+ * New upstream release
+ * debian/copyright:
+ - Added license link.
+ - Updated copyright years.
+ - Removed copyright info for files no longer in distribution.
+
+ -- Nuno Carvalho <[EMAIL PROTECTED]> Sat, 16 Aug 2008 14:15:14 +0200
+
parrot (0.5.1-1) unstable; urgency=low
* New upstream release (Closes: #444707).
Modified: branches/gsoc_pdd09/ports/debian/control.in
==============================================================================
--- branches/gsoc_pdd09/ports/debian/control.in (original)
+++ branches/gsoc_pdd09/ports/debian/control.in Tue Aug 19 14:08:02 2008
@@ -34,7 +34,7 @@
Package: libparrot-dev
Architecture: any
Section: libdevel
-Depends: libparrot%SOVERSION% (= ${Source-Version}), parrot, libicu-dev
+Depends: libparrot%SOVERSION% (= ${binary:Version}), parrot, libicu-dev
Description: Virtual machine for dynamic languages
Parrot is a virtual machine designed to efficiently compile and execute
bytecode for dynamic languages. Parrot currently hosts a variety of language
Modified: branches/gsoc_pdd09/ports/debian/copyright
==============================================================================
--- branches/gsoc_pdd09/ports/debian/copyright (original)
+++ branches/gsoc_pdd09/ports/debian/copyright Tue Aug 19 14:08:02 2008
@@ -8,7 +8,7 @@
Copyright for most of the code is held by:
-Copyright (C) 2001-2007, The Perl Foundation.
+Copyright (C) 2001-2008, The Perl Foundation.
Some files have a different copyright:
@@ -22,9 +22,6 @@
languages/urm:
2003 (c) by Marcus Thiesen
-lib/Digest/Perl/MD5.pm:
-Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All rights
reserved.
-
lib/Pod/:
Copyright (c) 2001-2002 Sean M. Burke. All rights reserved.
Modified: branches/gsoc_pdd09/ports/debian/libparrot-dev.install
==============================================================================
--- branches/gsoc_pdd09/ports/debian/libparrot-dev.install (original)
+++ branches/gsoc_pdd09/ports/debian/libparrot-dev.install Tue Aug 19
14:08:02 2008
@@ -1,4 +1,3 @@
usr/include/*
-usr/bin/parrot-config
usr/lib/libparrot.a
usr/lib/pkgconfig/parrot.pc
Modified: branches/gsoc_pdd09/ports/debian/parrot-doc.docs
==============================================================================
--- branches/gsoc_pdd09/ports/debian/parrot-doc.docs (original)
+++ branches/gsoc_pdd09/ports/debian/parrot-doc.docs Tue Aug 19 14:08:02 2008
@@ -1,125 +1,134 @@
-docs/art/pp001-intro.pod
-docs/art/pp002-pmc.pod
-docs/art/pp003-oop.pod
-docs/book/ch01_overview.pod
-docs/book/ch02_getting_started.pod
-docs/book/ch03_pir_basics.pod
-docs/book/ch04_pir_subroutines.pod
-docs/book/ch05_pasm.pod
-docs/book/ch06_testing.pod
-docs/book/ch07_architecture.pod
-docs/book/ch08_reference.pod
-docs/compiler_faq.pod
-docs/configuration.pod
-docs/debugger.pod
-docs/debug.pod
-docs/dev/byteorder.pod
-docs/dev/debugging_with_msvc.pod
-docs/dev/dod.pod
-docs/dev/events.pod
-docs/dev/fhs.pod
-docs/dev/headerizer.pod
-docs/dev/infant.pod
-docs/dev/jit_i386.pod
-docs/dev/longopt.pod
-docs/dev/optimizer.pod
-docs/dev/parrot_api.pod
-docs/dev/pccmethods.pod
-docs/dev/pcc_state.pod
-docs/dev/pmc_freeze.pod
-docs/dev/pmc_obj_design_meeting_notes.pod
-docs/dev/seatbelts.pod
-docs/embed.pod
-docs/extend.pod
-docs/faq.pod
-docs/gettingstarted.pod
-docs/glossary.pod
-docs/imcc/imcc.pod
-docs/imcc/imcfaq.pod
-docs/imcc/macros.pod
-docs/imcc/operation.pod
-docs/imcc/parsing.pod
-docs/intro.pod
-docs/jit.pod
-docs/memory_internals.pod
-docs/mmd.pod
-docs/native_exec.pod
-docs/ops/core.pod
+docs/ops/cmp.pod
+docs/ops/set.pod
+docs/ops/pic.pod
+docs/ops/string.pod
docs/ops/debug.pod
-docs/ops/experimental.pod
docs/ops/io.pod
-docs/ops/math.pod
-docs/ops/object.pod
-docs/ops/obscure.pod
-docs/ops/pic.pod
-docs/ops/pmc.pod
-docs/ops/set.pod
-docs/ops/stack.pod
+docs/ops/bit.pod
+docs/ops/core.pod
docs/ops/stm.pod
-docs/ops/string.pod
+docs/ops/object.pod
docs/ops/sys.pod
+docs/ops/math.pod
+docs/ops/obscure.pod
docs/ops/var.pod
-docs/optable.pod
+docs/ops/experimental.pod
+docs/ops/pmc.pod
+docs/submissions.pod
+docs/jit.pod
+docs/vtables.pod
+docs/stm/atomic.pod
+docs/stm/internals.pod
+docs/stm/stm_frontend.pod
+docs/stm/thread-issues.pod
+docs/stm/howto.pod
+docs/Makefile
docs/overview.pod
-docs/parrotbyte.pod
-docs/parrothist.pod
-docs/parrot.pod
-docs/pdds/draft/pdd01_overview.pod
-docs/pdds/draft/pdd04_datatypes.pod
-docs/pdds/draft/pdd05_opfunc.pod
-docs/pdds/draft/pdd06_pasm.pod
-docs/pdds/draft/pdd08_keys.pod
-docs/pdds/draft/pdd09_gc.pod
+docs/debug.pod
+docs/resources/up.gif
+docs/resources/favicon.ico
+docs/resources/perl.css
+docs/resources/parrot_small.png
+docs/imcc/operation.pod
+docs/imcc/README
+docs/imcc/imcfaq.pod
+docs/pdds/pdd28_strings.pod
+docs/pdds/pdd09_gc.pod
+docs/pdds/pdd24_events.pod
+docs/pdds/pdd15_object_metamodel.svg
+docs/pdds/pdd18_security.pod
+docs/pdds/pdd22_io.pod
+docs/pdds/README
+docs/pdds/pdd03_calling_conventions.pod
+docs/pdds/pdd27_multiple_dispatch.pod
+docs/pdds/pdd00_pdd.pod
+docs/pdds/pdd15_objects.pod
docs/pdds/draft/pdd10_embedding.pod
-docs/pdds/draft/pdd11_extending.pod
-docs/pdds/draft/pdd12_assembly.pod
-docs/pdds/draft/pdd14_bignum.pod
+docs/pdds/draft/pdd29_compiler_tools.pod
docs/pdds/draft/pdd16_native_call.pod
-docs/pdds/draft/pdd18_security.pod
+docs/pdds/draft/pdd14_bignum.pod
+docs/pdds/draft/pdd08_keys.pod
+docs/pdds/draft/pdd06_pasm.pod
+docs/pdds/draft/pdd11_extending.pod
+docs/pdds/draft/pdd04_datatypes.pod
docs/pdds/draft/pdd19_pir.pod
-docs/pdds/pdd00_pdd.pod
-docs/pdds/pdd03_calling_conventions.pod
+docs/pdds/draft/pdd05_opfunc.pod
+docs/pdds/draft/pdd01_overview.pod
docs/pdds/pdd07_codingstd.pod
+docs/pdds/pdd25_concurrency.pod
docs/pdds/pdd13_bytecode.pod
-docs/pdds/pdd15_objects.pod
-docs/pdds/pdd17_pmc.pod
docs/pdds/pdd20_lexical_vars.pod
-docs/pdds/pdd21_namespaces.pod
-docs/pdds/pdd22_io.pod
+docs/pdds/pdd15_object_metamodel.png
docs/pdds/pdd23_exceptions.pod
-docs/pdds/pdd24_events.pod
-docs/pdds/pdd25_concurrency.pod
+docs/pdds/pdd21_namespaces.pod
+docs/pdds/pdd17_pmc.pod
docs/pdds/pdd26_ast.pod
docs/pdds/pdd_template.pod
-docs/pdds/README
-docs/pmc2c.pod
-docs/pmc/array.pod
-docs/pmc/documentation.pod
-docs/pmc.pod
-docs/pmc/struct.pod
-docs/pmc/subs.pod
-docs/porting_intro.pod
-docs/project/cage_cleaners_guide.pod
+docs/glossary.pod
+docs/faq.pod
+docs/project/roles_responsibilities.pod
docs/project/committer_guide.pod
+docs/project/release_manager_guide.pod
docs/project/metacommitter_guide.pod
docs/project/pause_guide.pod
-docs/project/release_manager_guide.pod
+docs/project/cage_cleaners_guide.pod
docs/project/ticket_wrangler_guide.pod
-docs/req/model_users.pod
-docs/resources/favicon.ico
-docs/resources/parrot_small.png
-docs/resources/perl.css
-docs/resources/up.gif
-docs/ROADMAP.pod
-docs/roles_responsibilities.pod
+docs/project/debian_packaging_guide.pod
+docs/packfile-c.pod
+docs/memory_internals.pod
+docs/parrothist.pod
+docs/gettingstarted.pod
+docs/book/ch04_pir_subroutines.pod
+docs/book/ch01_overview.pod
+docs/book/ch05_pasm.pod
+docs/book/ch06_testing.pod
+docs/book/ch08_reference.pod
+docs/book/ch02_getting_started.pod
+docs/book/ch03_pir_basics.pod
+docs/book/ch07_architecture.pod
+docs/book/appendix.pod
+docs/book/figs/p6e_0801.png
+docs/debugger.pod
docs/running.pod
+docs/req/model_users.pod
+docs/optable.pod
+docs/intro.pod
docs/stability.pod
-docs/stm/atomic.pod
-docs/stm/howto.pod
-docs/stm/internals.pod
-docs/stm/stm_frontend.pod
-docs/stm/thread-issues.pod
-docs/strings.pod
-docs/submissions.pod
docs/tests.pod
-docs/vtables.pod
+docs/pmc/subs.pod
+docs/pmc/struct.pod
+docs/pmc/documentation.pod
+docs/pmc/array.pod
+docs/porting_intro.pod
+docs/extend.pod
+docs/parrot.pod
+docs/mmd.pod
+docs/embed.pod
+docs/compiler_faq.pod
+docs/native_exec.pod
+docs/dev/pmc_obj_design_meeting_notes.pod
+docs/dev/seatbelts.pod
+docs/dev/events.pod
+docs/dev/debugging_with_msvc.pod
+docs/dev/infant.pod
+docs/dev/fhs.pod
+docs/dev/pcc_state.pod
+docs/dev/jit_i386.pod
+docs/dev/headerizer.pod
+docs/dev/longopt.pod
+docs/dev/byteorder.pod
+docs/dev/parrot_api.pod
+docs/dev/pccmethods.pod
+docs/dev/optimizer.pod
+docs/dev/pmc_freeze.pod
+docs/ROADMAP.pod
+docs/art/pp003-oop.pod
+docs/art/pp002-pmc.pod
+docs/art/pp001-intro.pod
+docs/configuration.pod
+docs/pmc.pod
+docs/pct/past_building_blocks.pod
+docs/pct/pct_optable_guide.pod
+docs/pct/gettingstarted.pod
+docs/pmc2c.pod
+docs/parrotbyte.pod
Modified: branches/gsoc_pdd09/ports/debian/parrot.docs
==============================================================================
--- branches/gsoc_pdd09/ports/debian/parrot.docs (original)
+++ branches/gsoc_pdd09/ports/debian/parrot.docs Tue Aug 19 14:08:02 2008
@@ -1,7 +1,116 @@
-CREDITS
-DEPRECATED.pod
-NEWS
-PBC_COMPAT
-PLATFORMS
-RESPONSIBLE_PARTIES
-TODO
+docs/submissions.pod
+docs/jit.pod
+docs/vtables.pod
+docs/stm/atomic.pod
+docs/stm/internals.pod
+docs/stm/stm_frontend.pod
+docs/stm/thread-issues.pod
+docs/stm/howto.pod
+docs/overview.pod
+docs/debug.pod
+docs/resources/up.gif
+docs/resources/favicon.ico
+docs/resources/perl.css
+docs/resources/parrot_small.png
+docs/imcc/operation.pod
+docs/imcc/README
+docs/imcc/imcfaq.pod
+docs/pdds/pdd28_strings.pod
+docs/pdds/pdd09_gc.pod
+docs/pdds/pdd24_events.pod
+docs/pdds/pdd15_object_metamodel.svg
+docs/pdds/pdd18_security.pod
+docs/pdds/pdd22_io.pod
+docs/pdds/README
+docs/pdds/pdd03_calling_conventions.pod
+docs/pdds/pdd27_multiple_dispatch.pod
+docs/pdds/pdd00_pdd.pod
+docs/pdds/pdd15_objects.pod
+docs/pdds/draft/pdd10_embedding.pod
+docs/pdds/draft/pdd29_compiler_tools.pod
+docs/pdds/draft/pdd16_native_call.pod
+docs/pdds/draft/pdd14_bignum.pod
+docs/pdds/draft/pdd08_keys.pod
+docs/pdds/draft/pdd06_pasm.pod
+docs/pdds/draft/pdd11_extending.pod
+docs/pdds/draft/pdd04_datatypes.pod
+docs/pdds/draft/pdd19_pir.pod
+docs/pdds/draft/pdd05_opfunc.pod
+docs/pdds/draft/pdd01_overview.pod
+docs/pdds/pdd07_codingstd.pod
+docs/pdds/pdd25_concurrency.pod
+docs/pdds/pdd13_bytecode.pod
+docs/pdds/pdd20_lexical_vars.pod
+docs/pdds/pdd15_object_metamodel.png
+docs/pdds/pdd23_exceptions.pod
+docs/pdds/pdd21_namespaces.pod
+docs/pdds/pdd17_pmc.pod
+docs/pdds/pdd26_ast.pod
+docs/pdds/pdd_template.pod
+docs/glossary.pod
+docs/faq.pod
+docs/project/roles_responsibilities.pod
+docs/project/committer_guide.pod
+docs/project/release_manager_guide.pod
+docs/project/metacommitter_guide.pod
+docs/project/pause_guide.pod
+docs/project/cage_cleaners_guide.pod
+docs/project/ticket_wrangler_guide.pod
+docs/project/debian_packaging_guide.pod
+docs/memory_internals.pod
+docs/parrothist.pod
+docs/gettingstarted.pod
+docs/book/ch04_pir_subroutines.pod
+docs/book/ch01_overview.pod
+docs/book/ch05_pasm.pod
+docs/book/ch06_testing.pod
+docs/book/ch08_reference.pod
+docs/book/ch02_getting_started.pod
+docs/book/ch03_pir_basics.pod
+docs/book/ch07_architecture.pod
+docs/book/appendix.pod
+docs/book/figs/p6e_0801.png
+docs/debugger.pod
+docs/running.pod
+docs/req/model_users.pod
+docs/optable.pod
+docs/intro.pod
+docs/stability.pod
+docs/tests.pod
+docs/pmc/subs.pod
+docs/pmc/struct.pod
+docs/pmc/documentation.pod
+docs/pmc/array.pod
+docs/porting_intro.pod
+docs/extend.pod
+docs/parrot.pod
+docs/mmd.pod
+docs/embed.pod
+docs/compiler_faq.pod
+docs/native_exec.pod
+docs/dev/pmc_obj_design_meeting_notes.pod
+docs/dev/seatbelts.pod
+docs/dev/events.pod
+docs/dev/debugging_with_msvc.pod
+docs/dev/infant.pod
+docs/dev/fhs.pod
+docs/dev/pcc_state.pod
+docs/dev/jit_i386.pod
+docs/dev/headerizer.pod
+docs/dev/longopt.pod
+docs/dev/byteorder.pod
+docs/dev/parrot_api.pod
+docs/dev/pccmethods.pod
+docs/dev/optimizer.pod
+docs/dev/pmc_freeze.pod
+docs/ROADMAP.pod
+docs/art/pp003-oop.pod
+docs/art/pp002-pmc.pod
+docs/art/pp001-intro.pod
+docs/configuration.pod
+docs/pmc.pod
+docs/pct/past_building_blocks.pod
+docs/pct/pct_optable_guide.pod
+docs/pct/gettingstarted.pod
+docs/pmc2c.pod
+docs/parrotbyte.pod
Modified: branches/gsoc_pdd09/ports/debian/parrot.install
==============================================================================
--- branches/gsoc_pdd09/ports/debian/parrot.install (original)
+++ branches/gsoc_pdd09/ports/debian/parrot.install Tue Aug 19 14:08:02 2008
@@ -1,5 +1,5 @@
usr/bin/parrot
-usr/bin/disassemble
+usr/bin/pbc_disassemble
usr/bin/pbc_info
usr/bin/pbc_merge
usr/bin/pdump
Modified: branches/gsoc_pdd09/ports/debian/rules
==============================================================================
--- branches/gsoc_pdd09/ports/debian/rules (original)
+++ branches/gsoc_pdd09/ports/debian/rules Tue Aug 19 14:08:02 2008
@@ -25,9 +25,9 @@
dh_testdir
$(MAKE) installable
pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" docs/running.pod debian/parrot.1
- pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" parrot-config debian/parrot-config.1
+ pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" parrot_config debian/parrot_config.1
pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/pdump.c debian/pdump.1
- pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/disassemble.c debian/disassemble.1
+ pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/pbc_disassemble.c debian/pbc_disassemble.1
pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/pdb.c debian/parrot-debugger.1
pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/pbc_info.c debian/pbc_info.1
pod2man --section=1 --release="Debian Project" --center="Debian
GNU/Linux manual" src/pbc_merge.c debian/pbc_merge.1
@@ -36,8 +36,8 @@
clean:
dh_testdir
dh_testroot
- rm -f build-stamp configure-stamp debian/parrot.1
debian/parrot-config.1 debian/pdump.1 debian/disassemble.1
debian/parrot-debugger.1 debian/pbc_info.1 debian/pbc_merge.1
debian/libparrot$(SOVERSION).install src/nci_test.o src/main.o
ext/Parrot-Embed/Makefile.PL languages/PIR/Makefile languages/perl5/Makefile
languages/pynie/Makefile runtime/parrot/include/signal.pasm test.c test.ldo
- -$(MAKE) realclean
+ rm -f build-stamp configure-stamp debian/parrot.1
debian/parrot_config.1 debian/pdump.1 debian/pbc_disassemble.1
debian/parrot-debugger.1 debian/pbc_info.1 debian/pbc_merge.1
debian/libparrot$(SOVERSION).install src/nci_test.o src/main.o
ext/Parrot-Embed/Makefile.PL languages/PIR/Makefile languages/perl5/Makefile
languages/pynie/Makefile runtime/parrot/include/signal.pasm test.c test.ldo
+ [ ! -f Makefile ] || $(MAKE) distclean
dh_clean
debian/libparrot$(SOVERSION).install: debian/libparrot.install VERSION
@@ -61,7 +61,7 @@
dh_testdir -i
dh_testroot -i
dh_installchangelogs -i ChangeLog
- dh_installman -plibparrot-dev debian/parrot-config.1
+ dh_installman -plibparrot-dev debian/parrot_config.1
dh_installdocs -i
dh_link -plibparrot-dev usr/lib/libparrot.so.$(SOVERSION)
usr/lib/libparrot.so
dh_compress -pparrot-doc -X.pod
@@ -77,7 +77,7 @@
dh_testdir -a
dh_testroot -a
dh_installchangelogs -a ChangeLog
- dh_installman -pparrot debian/parrot.1 debian/pdump.1
debian/disassemble.1 debian/parrot-debugger.1 debian/pbc_info.1
debian/pbc_merge.1
+ dh_installman -pparrot debian/parrot.1 debian/pdump.1
debian/pbc_disassemble.1 debian/parrot-debugger.1 debian/pbc_info.1
debian/pbc_merge.1
dh_installdocs -a
dh_strip -a
dh_compress -a
Modified: branches/gsoc_pdd09/src/debug.c
==============================================================================
--- branches/gsoc_pdd09/src/debug.c (original)
+++ branches/gsoc_pdd09/src/debug.c Tue Aug 19 14:08:02 2008
@@ -406,6 +406,7 @@
PDB_run_command(interp, command);
}
+ TRACEDEB_MSG("debugger_cmdline finished");
}
static void
@@ -415,6 +416,9 @@
if (interp->pdb->script_file) {
fclose(interp->pdb->script_file);
interp->pdb->script_file = NULL;
+ interp->pdb->state|= PDB_STOPPED;
+ interp->pdb->last_command[0] = '\0';
+ interp->pdb->cur_command[0] = '\0';
}
}
@@ -499,6 +503,8 @@
{
char *file;
+ TRACEDEB_MSG("Parrot_debugger_load");
+
if (!interp->pdb)
Parrot_ex_throw_from_c_args(interp, NULL, 0, "No debugger");
@@ -638,14 +644,12 @@
FILE *fd = interp->pdb->script_file;
char buf[DEBUG_CMD_BUFFER_LENGTH+1];
char *ptr = buf;
- buf[0]='\0';
- if (feof(fd)) {
- close_script_file(interp);
- return;
- }
do {
- fgets(buf, DEBUG_CMD_BUFFER_LENGTH, fd);
+ if (fgets(buf, DEBUG_CMD_BUFFER_LENGTH, fd) == NULL) {
+ close_script_file(interp);
+ return;
+ }
/* skip spaces */
for (ptr = (char *)&buf; *ptr && isspace((unsigned char)*ptr);
ptr++);
@@ -655,7 +659,6 @@
continue;
} while (0);
- buf[strlen(buf)-1]='\0';
/* RT #46117: handle command error and print out script line
* PDB_run_command should return non-void value?
* stop execution of script if fails
@@ -667,7 +670,6 @@
close_script_file(interp);
return;
}
- strcpy(pdb->cur_command, buf);
}
else {
@@ -715,6 +717,8 @@
{
FILE *fd;
+ TRACEDEB_MSG("PDB_script_file");
+
/* If already executing a script, close it */
close_script_file(interp);
@@ -728,6 +732,7 @@
return;
}
interp->pdb->script_file = fd;
+ TRACEDEB_MSG("PDB_script_file finished");
}
/*
@@ -1858,6 +1863,8 @@
/* Write the opcode name */
const char * p = full_name ? info->full_name : info->name;
+ TRACEDEB_MSG("PDB_disassemble_op");
+
if (! p)
p= "**UNKNOWN**";
strcpy(dest, p);
@@ -2074,7 +2081,7 @@
" :unused004",
" :unused008",
" :const",
- " :flat", /* should be :slurpy for args */
+ " :flat", /* should be :slurpy for args */
" :unused040",
" :optional",
" :opt_flag",
@@ -2156,6 +2163,8 @@
size_t space; /* How much space do we have? */
size_t size, alloced, n;
+ TRACEDEB_MSG("PDB_disassemble");
+
pfile = mem_allocate_typed(PDB_file_t);
pline = mem_allocate_typed(PDB_line_t);
@@ -2351,9 +2360,12 @@
PDB_file_t *pfile;
PDB_line_t *pline;
PDB_t * const pdb = interp->pdb;
- opcode_t *pc = pdb->cur_opcode;
+ opcode_t *pc = interp->code->base.data;
+
unsigned long size = 0;
+ TRACEDEB_MSG("PDB_load_source");
+
/* If there was a file already loaded or the bytecode was
disassembled, free it */
if (pdb->file)
@@ -2383,6 +2395,9 @@
pfile->line = pline;
pline->number = 1;
+ PARROT_ASSERT(interp->op_info_table);
+ PARROT_ASSERT(pc);
+
while ((c = fgetc(file)) != EOF) {
/* Grow it */
if (++size == 1024) {
@@ -2417,6 +2432,8 @@
pdb->state |= PDB_SRC_LOADED;
pdb->file = pfile;
+
+ TRACEDEB_MSG("PDB_load_source finished");
}
/*
Modified: branches/gsoc_pdd09/src/inter_call.c
==============================================================================
--- branches/gsoc_pdd09/src/inter_call.c (original)
+++ branches/gsoc_pdd09/src/inter_call.c Tue Aug 19 14:08:02 2008
@@ -632,7 +632,10 @@
=item C<int Parrot_fetch_arg_nci>
-RT#48260: Not yet documented!!!
+Fetches the next argument from the call state and converts it to the proper
+data type for the call signature. If the next argument is a slurpy array,
+all the remaining arguments are slurped together into a ResizablePMCArray
+PMC which is then set as the PMC value of the call_state object.
=cut
@@ -1039,7 +1042,9 @@
=item C<int Parrot_store_arg>
-RT#48260: Not yet documented!!!
+Stores the next function argument into the appropriate destination register.
+Calls C<store_arg> to do most of the work. Returns 0 if an attempt is made
+to store more values then there are in the signature. Returns 1 otherwise.
=cut
Modified: branches/gsoc_pdd09/src/interpreter.c
==============================================================================
--- branches/gsoc_pdd09/src/interpreter.c (original)
+++ branches/gsoc_pdd09/src/interpreter.c Tue Aug 19 14:08:02 2008
@@ -275,6 +275,10 @@
opinfo = &interp->op_info_table[*pc];
/* first arguments - PIC needs it */
+
+ /* check for RT#58044 */
+ PARROT_ASSERT(CONTEXT(interp)->n_regs_used);
+
prederef_args(pc_prederef, interp, pc, opinfo);
switch (type) {
Modified: branches/gsoc_pdd09/src/library.c
==============================================================================
--- branches/gsoc_pdd09/src/library.c (original)
+++ branches/gsoc_pdd09/src/library.c Tue Aug 19 14:08:02 2008
@@ -223,7 +223,9 @@
=item C<static int is_abs_path>
-RT#48260: Not yet documented!!!
+Determines whether a file name given by a fixed-8 or utf8 C<STRING> is an
+absolute file name. Returns C<1> if the filename is absolute, returns C<0>
+otherwise.
=cut
@@ -244,7 +246,7 @@
(strncmp(file_name+1, ":\\", 2) == 0 ||
strncmp(file_name+1, ":/", 2) == 0)))
#else
- if (file_name[0] == '/') /* XXX ../foo, ./bar */
+ if (file_name[0] == '/') /* XXX ../foo, ./bar */
#endif
{
return 1;
@@ -287,7 +289,10 @@
=item C<static STRING* path_finalize>
-RT#48260: Not yet documented!!!
+Ensures the given STRING C<path> has a C-style NULL character at the end. The
+length of the string is not increased to account for this NULL, however. In
+WIN32 systems, the path separator is switched from the unix-style "/" to the
+Windows-style "\".
=cut
@@ -409,7 +414,9 @@
=item C<static STRING* try_load_path>
-RT#48260: Not yet documented!!!
+Attempts to load a file with name C<path>. If the file is successfully located,
+the finalized name of the file is returned as a STRING. Otherwise, returns
+NULL.
=cut
Modified: branches/gsoc_pdd09/src/parrot_debugger.c
==============================================================================
--- branches/gsoc_pdd09/src/parrot_debugger.c (original)
+++ branches/gsoc_pdd09/src/parrot_debugger.c Tue Aug 19 14:08:02 2008
@@ -209,6 +209,9 @@
fclose(imc_yyin_get(yyscanner));
PackFile_fixup_subs(interp, PBC_POSTCOMP, NULL);
+
+ /* load the source for debugger list */
+ PDB_load_source(interp, filename);
}
Parrot_unblock_GC_mark(interp);