com presentations: New debugging talk for PHPNW (and zendcon): slides/internals/vld2.xml slides/xdebug/agenda-ppp.xml
slides/xdebug/analyse-running-script.xml slides/xdebug/cli-color.xml slides/xdebug/komodo.xml slides/xdebug/library-kint.xml
slides/xdebug/library-krumo.xml slides/xdebug/library-ladybug.xml slides/xdebug/library-symfony.xml slides/xdebug/netbeans.xml
slides/xdebug/phpdbg-demo.xml slides/xdebug/phpdbg-past.xml slides/xdebug/phpdbg

From: Date: Wed, 15 Oct 2014 11:42:38 +0000
Subject: com presentations: New debugging talk for PHPNW (and zendcon): slides/internals/vld2.xml slides/xdebug/agenda-ppp.xml
slides/xdebug/analyse-running-script.xml slides/xdebug/cli-color.xml slides/xdebug/komodo.xml slides/xdebug/library-kint.xml
slides/xdebug/library-krumo.xml slides/xdebug/library-ladybug.xml slides/xdebug/library-symfony.xml slides/xdebug/netbeans.xml
slides/xdebug/phpdbg-demo.xml slides/xdebug/phpdbg-past.xml slides/xdebug/phpdbg
Groups: php.pres 
Request: Send a blank email to pres+get-2004@lists.php.net to get a copy of this message
Commit: 51f14501829dee3ad58f9df7fb84e38d52977530 Author: Derick Rethans <github@derickrethans.nl> Wed, 15 Oct 2014 12:42:38 +0100 Parents: 1a6bc0608c19979a1d998dcaea05f8c02f9f2ddb Branches: master Link: http://git.php.net/?p=presentations.git;a=commitdiff;h=51f14501829dee3ad58f9df7fb84e38d52977530 Log: New debugging talk for PHPNW (and zendcon) Changed paths: M slides/internals/vld2.xml A slides/xdebug/agenda-ppp.xml M slides/xdebug/analyse-running-script.xml M slides/xdebug/cli-color.xml M slides/xdebug/komodo.xml A slides/xdebug/library-kint.xml A slides/xdebug/library-krumo.xml A slides/xdebug/library-ladybug.xml A slides/xdebug/library-symfony.xml M slides/xdebug/netbeans.xml A slides/xdebug/phpdbg-demo.xml A slides/xdebug/phpdbg-past.xml A slides/xdebug/phpdbg.webm A slides/xdebug/phpdbg.xml A slides/xdebug/phpstorm.png A slides/xdebug/phpstorm.xml A slides/xdebug/restaurant-end-universe.jpg A slides/xdebug/restaurant.jpg A slides/xdebug/restaurant.xml M slides/xdebug/shutup.xml M slides/xdebug/tracing.xml A slides/xdebug/vld-path-1-code.png A slides/xdebug/vld-path-1-code.xml A slides/xdebug/vld-path-1-output.xml A slides/xdebug/vld-path-1-paths-colour.png A slides/xdebug/vld-path-1-paths-colour.xml A slides/xdebug/vld-path-1-paths.png A slides/xdebug/vld-path-1-paths.xml A slides/xdebug/vld-path-2-code.xml A slides/xdebug/vld-path-2-output.xml A slides/xdebug/vld-path-2-paths.png A slides/xdebug/vld-path-2-paths.xml A slides/xdebug/vld-path-3-code.xml A slides/xdebug/vld-path-3-output.xml A slides/xdebug/vld-path-3-paths.png A slides/xdebug/vld-path-3-paths.xml M slides/xdebug/xdebug-var-dump.xml M templates/default/slide.ezt A xdebug-phpnw14.xml

diff --git a/slides/internals/vld2.xml b/slides/internals/vld2.xml index b7f77b5..34ced26 100644 --- a/slides/internals/vld2.xml +++ b/slides/internals/vld2.xml @@ -1,15 +1,13 @@ <?xml version="1.0" encoding="ISO-8859-1"?> <slide fontsize="6em"> - <title>Compiling</title> - <subtitle>Disassembler</subtitle> + <title>vld</title> - <blurb>Disassembler: vld</blurb> <blurb>Dumps oparray per element:</blurb> <list marginleft="3em" fontsize="4em"> <bullet>main script</bullet> <bullet>function</bullet> <bullet>class method</bullet> - <bullet>path analysis and dead code analysis</bullet> + <bullet>dead code analysis</bullet> </list> <break/> <blurb>Usage:</blurb> diff --git a/slides/xdebug/agenda-ppp.xml b/slides/xdebug/agenda-ppp.xml new file mode 100644 index 0000000..969d93a --- /dev/null +++ b/slides/xdebug/agenda-ppp.xml @@ -0,0 +1,8 @@ +<slide> +<title>Today's agenda</title> +<list> + <bullet>Past</bullet> + <bullet>Present</bullet> + <bullet>Future</bullet> +</list> +</slide> diff --git a/slides/xdebug/analyse-running-script.xml b/slides/xdebug/analyse-running-script.xml index acc442c..8b022ef 100644 --- a/slides/xdebug/analyse-running-script.xml +++ b/slides/xdebug/analyse-running-script.xml @@ -4,13 +4,11 @@ <list> <bullet>DBGp, common Debugging protocol</bullet> - <bullet>Cross-language: PHP, Python, Perl...</bullet> + <bullet>Cross-language: PHP, *HHVM*, Python, Perl...</bullet> </list> <break/> <list> - <bullet>Eclipse/PDT (Java based — free)</bullet> <bullet>Komodo (Linux, Windows, Mac — commercial)</bullet> - <bullet>MacGDBp (free)</bullet> <bullet>Netbeans (Java-based — free)</bullet> <bullet>PHPStorm (Java-based — commercial)</bullet> <bullet>(and many others: <link href="http://xdebug.org/docs/remote#clients"/>)</bullet> diff --git a/slides/xdebug/cli-color.xml b/slides/xdebug/cli-color.xml index 7875862..4ac9cd5 100644 --- a/slides/xdebug/cli-color.xml +++ b/slides/xdebug/cli-color.xml @@ -1,5 +1,4 @@ -<?xml version="1.0" encoding="ISO-8859-1"?> -<slide> +<slide style="past"> <title>Colours on the Command Line</title> <subtitle>*new in 2.2*</subtitle> diff --git a/slides/xdebug/komodo.xml b/slides/xdebug/komodo.xml index dce2ab9..520086d 100644 --- a/slides/xdebug/komodo.xml +++ b/slides/xdebug/komodo.xml @@ -1 +1 @@ -<slide><break/><image filename="komodo2.png"/></slide> +<slide style="past"><title>Komodo</title><break/><image filename="komodo2.png"/></slide> diff --git a/slides/xdebug/library-kint.xml b/slides/xdebug/library-kint.xml new file mode 100644 index 0000000..04d1ae5 --- /dev/null +++ b/slides/xdebug/library-kint.xml @@ -0,0 +1,5 @@ +<slide style="past"> +<title>Kint</title> +<blurb>https://github.com/raveren/kint.git</blurb> +<iframe filename="http://whisky/test/xdebug/var_dump-kint.php"/> +</slide> diff --git a/slides/xdebug/library-krumo.xml b/slides/xdebug/library-krumo.xml new file mode 100644 index 0000000..26052ff --- /dev/null +++ b/slides/xdebug/library-krumo.xml @@ -0,0 +1,5 @@ +<slide style="past"> +<title>Krumo</title> +<blurb>https://github.com/oodle/krumo.git</blurb> +<iframe filename="http://whisky/test/xdebug/var_dump-krumo.php"/> +</slide> diff --git a/slides/xdebug/library-ladybug.xml b/slides/xdebug/library-ladybug.xml new file mode 100644 index 0000000..a2941c2 --- /dev/null +++ b/slides/xdebug/library-ladybug.xml @@ -0,0 +1,5 @@ +<slide style="past"> +<title>Ladybug</title> +<blurb>https://github.com/raulfraile/ladybug.git</blurb> +<iframe filename="http://whisky/test/xdebug/var_dump-ladybug.php"/> +</slide> diff --git a/slides/xdebug/library-symfony.xml b/slides/xdebug/library-symfony.xml new file mode 100644 index 0000000..4d1d94e --- /dev/null +++ b/slides/xdebug/library-symfony.xml @@ -0,0 +1,5 @@ +<slide style="past"> +<title>Symfony var-dumper</title> +<blurb>https://github.com/symfony/var-dumper.git</blurb> +<iframe filename="http://whisky/test/xdebug/var_dump-symfony.php"/> +</slide> diff --git a/slides/xdebug/netbeans.xml b/slides/xdebug/netbeans.xml index e3d0c3a..6a23664 100644 --- a/slides/xdebug/netbeans.xml +++ b/slides/xdebug/netbeans.xml @@ -1 +1 @@ -<slide><break/><image filename="netbeans.jpg"/></slide> +<slide style="past"><title>Netbeans</title><break/><image filename="netbeans.jpg"/></slide> diff --git a/slides/xdebug/phpdbg-demo.xml b/slides/xdebug/phpdbg-demo.xml new file mode 100644 index 0000000..e9836fd --- /dev/null +++ b/slides/xdebug/phpdbg-demo.xml @@ -0,0 +1,4 @@ +<slide style="future"> +<title>PHPDBG</title> +<video filename="phpdbg.webm"/> +</slide> diff --git a/slides/xdebug/phpdbg-past.xml b/slides/xdebug/phpdbg-past.xml new file mode 100644 index 0000000..b046899 --- /dev/null +++ b/slides/xdebug/phpdbg-past.xml @@ -0,0 +1,12 @@ +<slide style="past"> +<title>PHPDBG</title> + +<list> + <bullet>Extra SAPI module that comes with PHP 5.6</bullet> + <bullet>it takes itself very serious: + <blurb>~40:0 vote confirms the awesomeness.~</blurb> + </bullet> + <bullet>It does some things that Xdebug does, but not as good</bullet> + <bullet>It does some things that VLD does, but not as good</bullet> +</list> +</slide> diff --git a/slides/xdebug/phpdbg.webm b/slides/xdebug/phpdbg.webm new file mode 100644 index 0000000..44ce3ec Binary files /dev/null and b/slides/xdebug/phpdbg.webm differ diff --git a/slides/xdebug/phpdbg.xml b/slides/xdebug/phpdbg.xml new file mode 100644 index 0000000..70c6986 --- /dev/null +++ b/slides/xdebug/phpdbg.xml @@ -0,0 +1,12 @@ +<slide style="future"> +<title>PHPDBG</title> + +<list> + <bullet>Extra SAPI module that comes with PHP 5.6</bullet> + <bullet>it takes itself very serious: + <blurb>~40:0 vote confirms the awesomeness.~</blurb> + </bullet> + <bullet>It does some things that Xdebug does, but not quite as good</bullet> + <bullet>It does some things that VLD does, but not quite as good</bullet> +</list> +</slide> diff --git a/slides/xdebug/phpstorm.png b/slides/xdebug/phpstorm.png new file mode 100644 index 0000000..6c5a239 Binary files /dev/null and b/slides/xdebug/phpstorm.png differ diff --git a/slides/xdebug/phpstorm.xml b/slides/xdebug/phpstorm.xml new file mode 100644 index 0000000..d6203de --- /dev/null +++ b/slides/xdebug/phpstorm.xml @@ -0,0 +1 @@ +<slide><title>PHP Storm</title><break/><image filename="phpstorm.png"/></slide> diff --git a/slides/xdebug/restaurant-end-universe.jpg b/slides/xdebug/restaurant-end-universe.jpg new file mode 100644 index 0000000..0fc91c5 Binary files /dev/null and b/slides/xdebug/restaurant-end-universe.jpg differ diff --git a/slides/xdebug/restaurant.jpg b/slides/xdebug/restaurant.jpg new file mode 100644 index 0000000..8ca419c Binary files /dev/null and b/slides/xdebug/restaurant.jpg differ diff --git a/slides/xdebug/restaurant.xml b/slides/xdebug/restaurant.xml new file mode 100644 index 0000000..f72891e --- /dev/null +++ b/slides/xdebug/restaurant.xml @@ -0,0 +1,5 @@ +<slide type="image"> + +<image filename="restaurant-end-universe.jpg"/> + +</slide> diff --git a/slides/xdebug/shutup.xml b/slides/xdebug/shutup.xml index 51a9f66..f3c7003 100644 --- a/slides/xdebug/shutup.xml +++ b/slides/xdebug/shutup.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="ISO-8859-1"?> -<slide fontsize="6em"> +<slide fontsize="6em" style="past"> <title>Scream</title> <list> diff --git a/slides/xdebug/tracing.xml b/slides/xdebug/tracing.xml index f757290..18a71e8 100644 --- a/slides/xdebug/tracing.xml +++ b/slides/xdebug/tracing.xml @@ -1,4 +1,4 @@ -<slide type="image"> +<slide> <title>Tracing</title> <image filename="highway-trace.jpg"/> diff --git a/slides/xdebug/vld-path-1-code.png b/slides/xdebug/vld-path-1-code.png new file mode 100644 index 0000000..17d8448 Binary files /dev/null and b/slides/xdebug/vld-path-1-code.png differ diff --git a/slides/xdebug/vld-path-1-code.xml b/slides/xdebug/vld-path-1-code.xml new file mode 100644 index 0000000..18ae459 --- /dev/null +++ b/slides/xdebug/vld-path-1-code.xml @@ -0,0 +1,42 @@ +<slide> +<title>vld paths #1: code</title> + +<example> +<![CDATA[<?php +class ExceptionFoo extends Exception {} +class ExceptionBar extends Exception {} +class ExceptionBaz extends Exception {} + +function trycatch($action) +{ + echo "Let's do some stuff!\n"; + $f = 5 * pow(3, 7); + + try { + switch ($action) { + case 1: throw new ExceptionFoo("test"); + case 2: throw new ExceptionBaz("test"); + case 3: throw new Exception("test"); + } + echo "Not thrown\n"; + } catch (ExceptionFoo $e) { + echo "caught\n"; + } catch (ExceptionBar $e) { + echo "caught\n"; + } catch (ExceptionBaz $e) { + echo "caught\n"; + } + + echo "And do some more\n"; +} + +trycatch(1); +trycatch(2); +try { + trycatch(3); +} catch ( Exception $e ) { + echo "CAUGHT IN MAIN\n"; +} +?>]]> +</example> +</slide> diff --git a/slides/xdebug/vld-path-1-output.xml b/slides/xdebug/vld-path-1-output.xml new file mode 100644 index 0000000..6c660a9 --- /dev/null +++ b/slides/xdebug/vld-path-1-output.xml @@ -0,0 +1,142 @@ +<slide> +<title>vld paths #1: output</title> + +<example> +<![CDATA[ +Function trycatch: +Finding entry points +Branch analysis from position: 0 +Jump found. Position 1 = 17, Position 2 = 26 +Branch analysis from position: 17 +Jump found. Position 1 = -2 +Branch analysis from position: 26 +Jump found. Position 1 = 29, Position 2 = 38 +Branch analysis from position: 29 +Jump found. Position 1 = -2 +Branch analysis from position: 38 +Jump found. Position 1 = 41, Position 2 = 50 +Branch analysis from position: 41 +Jump found. Position 1 = -2 +Branch analysis from position: 50 +Jump found. Position 1 = 64 +Branch analysis from position: 64 +Jump found. Position 1 = -2 +Found catch point at position: 53 +Branch analysis from position: 53 +Jump found. Position 1 = 54, Position 2 = 57 +Branch analysis from position: 54 +Jump found. Position 1 = 64 +Branch analysis from position: 64 +Branch analysis from position: 57 +Jump found. Position 1 = 58, Position 2 = 61 +Branch analysis from position: 58 +Jump found. Position 1 = 64 +Branch analysis from position: 64 +Branch analysis from position: 61 +Jump found. Position 1 = 62, Position 2 = -2 +Branch analysis from position: 62 +Jump found. Position 1 = -2 +Found catch point at position: 57 +Branch analysis from position: 57 +Found catch point at position: 61 +Branch analysis from position: 61 +filename: /home/derick/dev/php/derickr-xdebug/tests/bug01034-003.inc +function name: trycatch +number of ops: 68 +compiled vars: !0 = $action, !1 = $f, !2 = $e +line #* E I O op fetch ext return operands +------------------------------------------------------------------------------------- + 6 0 E > EXT_NOP + 1 RECV !0 + 8 2 EXT_STMT + 3 ECHO 'Let%27s+do+some+stuff%21%0A' + 9 4 EXT_STMT + 5 EXT_FCALL_BEGIN + 6 SEND_VAL 3 + 7 SEND_VAL 7 + 8 DO_FCALL 2 $0 'pow' + 9 EXT_FCALL_END + 10 MUL ~1 5, $0 + 11 ASSIGN !1, ~1 + 11 12 NOP + 12 13 NOP + 13 14 EXT_STMT + 15 CASE ~3 !0, 1 + 16 > JMPZ ~3, ->26 + 17 > EXT_STMT + 18 FETCH_CLASS 4 :4 'ExceptionFoo' + 19 EXT_FCALL_BEGIN + 20 NEW $5 :4 + 21 SEND_VAL 'test' + 22 DO_FCALL_BY_NAME 1 + 23 EXT_FCALL_END + 24 > THROW 0 $5 + 14 25* JMP ->29 + 26 > EXT_STMT + 27 CASE ~3 !0, 2 + 28 > JMPZ ~3, ->38 + 29 > EXT_STMT + 30 FETCH_CLASS 4 :7 'ExceptionBaz' + 31 EXT_FCALL_BEGIN + 32 NEW $8 :7 + 33 SEND_VAL 'test' + 34 DO_FCALL_BY_NAME 1 + 35 EXT_FCALL_END + 36 > THROW 0 $8 + 15 37* JMP ->41 + 38 > EXT_STMT + 39 CASE ~3 !0, 3 + 40 > JMPZ ~3, ->50 + 41 > EXT_STMT + 42 FETCH_CLASS 4 :10 'Exception' + 43 EXT_FCALL_BEGIN + 44 NEW $11 :10 + 45 SEND_VAL 'test' + 46 DO_FCALL_BY_NAME 1 + 47 EXT_FCALL_END + 48 > THROW 0 $11 + 16 49* JMP ->50 + 17 50 > EXT_STMT + 51 ECHO 'Not+thrown%0A' + 18 52 > JMP ->64 + 53 E > > CATCH 57 'ExceptionFoo', !2 + 19 54 > EXT_STMT + 55 ECHO 'caught%0A' + 20 56 > JMP ->64 + 57 E > > CATCH 61 'ExceptionBar', !2 + 21 58 > EXT_STMT + 59 ECHO 'caught%0A' + 22 60 > JMP ->64 + 61 E > > CATCH 64 'ExceptionBaz', !2 + 23 62 > EXT_STMT + 63 ECHO 'caught%0A' + 26 64 > EXT_STMT + 65 ECHO 'And+do+some+more%0A' + 27 66 EXT_STMT + 67 > RETURN null + +branch: # 0; line: 6- 13; sop: 0; eop: 16; out1: 17; out2: 26 +branch: # 17; line: 13- 13; sop: 17; eop: 24; out1: -2 +branch: # 26; line: 14- 14; sop: 26; eop: 28; out1: 29; out2: 38 +branch: # 29; line: 14- 14; sop: 29; eop: 36; out1: -2 +branch: # 38; line: 15- 15; sop: 38; eop: 40; out1: 41; out2: 50 +branch: # 41; line: 15- 15; sop: 41; eop: 48; out1: -2 +branch: # 50; line: 17- 18; sop: 50; eop: 52; out1: 64 +branch: # 53; line: 18- 18; sop: 53; eop: 53; out1: 54; out2: 57 +branch: # 54; line: 19- 20; sop: 54; eop: 56; out1: 64 +branch: # 57; line: 20- 20; sop: 57; eop: 57; out1: 58; out2: 61 +branch: # 58; line: 21- 22; sop: 58; eop: 60; out1: 64 +branch: # 61; line: 22- 22; sop: 61; eop: 61; out1: 62; out2: -2 +branch: # 62; line: 23- 26; sop: 62; eop: 63; out1: 64 +branch: # 64; line: 26- 27; sop: 64; eop: 67; out1: -2 +path #1: 0, 17, +path #2: 0, 26, 29, +path #3: 0, 26, 38, 41, +path #4: 0, 26, 38, 50, 64, +path #5: 53, 54, 64, +path #6: 53, 57, 58, 64, +path #7: 53, 57, 61, 62, 64, +End of function trycatch +]]> +</example> +</slide> diff --git a/slides/xdebug/vld-path-1-paths-colour.png b/slides/xdebug/vld-path-1-paths-colour.png new file mode 100644 index 0000000..6834b27 Binary files /dev/null and b/slides/xdebug/vld-path-1-paths-colour.png differ diff --git a/slides/xdebug/vld-path-1-paths-colour.xml b/slides/xdebug/vld-path-1-paths-colour.xml new file mode 100644 index 0000000..6a6b8d0 --- /dev/null +++ b/slides/xdebug/vld-path-1-paths-colour.xml @@ -0,0 +1,44 @@ +<slide> + +<image align="right" filename="vld-path-1-paths-colour.png"/> + +<example> +<![CDATA[ 1 <?php + 2 class ExceptionFoo extends Exception {} + 3 class ExceptionBar extends Exception {} + 4 class ExceptionBaz extends Exception {} + 5 + 6 function trycatch($action) + 7 { + 8 echo "Let's do some stuff!\n"; + 9 $f = 5 * pow(3, 7); + 10 + 11 try { + 12 switch ($action) { + 13 case 1: throw new ExceptionFoo("test"); + 14 case 2: throw new ExceptionBaz("test"); + 15 case 3: throw new Exception("test"); + 16 } + 17 echo "Not thrown\n"; + 18 } catch (ExceptionFoo $e) { + 19 echo "caught\n"; + 20 } catch (ExceptionBar $e) { + 21 echo "caught\n"; + 22 } catch (ExceptionBaz $e) { + 23 echo "caught\n"; + 24 } + 25 + 26 echo "And do some more\n"; + 27 } + 28 + 29 trycatch(1); + 30 trycatch(2); + 31 try { + 32 trycatch(3); + 33 } catch ( Exception $e ) { + 34 echo "CAUGHT IN MAIN\n"; + 35 } + 36 ?>]]> +</example> + +</slide> diff --git a/slides/xdebug/vld-path-1-paths.png b/slides/xdebug/vld-path-1-paths.png new file mode 100644 index 0000000..293b82e Binary files /dev/null and b/slides/xdebug/vld-path-1-paths.png differ diff --git a/slides/xdebug/vld-path-1-paths.xml b/slides/xdebug/vld-path-1-paths.xml new file mode 100644 index 0000000..fc28974 --- /dev/null +++ b/slides/xdebug/vld-path-1-paths.xml @@ -0,0 +1,44 @@ +<slide> + +<image align="right" filename="vld-path-1-paths.png"/> + +<example> +<![CDATA[ 1 <?php + 2 class ExceptionFoo extends Exception {} + 3 class ExceptionBar extends Exception {} + 4 class ExceptionBaz extends Exception {} + 5 + 6 function trycatch($action) + 7 { + 8 echo "Let's do some stuff!\n"; + 9 $f = 5 * pow(3, 7); + 10 + 11 try { + 12 switch ($action) { + 13 case 1: throw new ExceptionFoo("test"); + 14 case 2: throw new ExceptionBaz("test"); + 15 case 3: throw new Exception("test"); + 16 } + 17 echo "Not thrown\n"; + 18 } catch (ExceptionFoo $e) { + 19 echo "caught\n"; + 20 } catch (ExceptionBar $e) { + 21 echo "caught\n"; + 22 } catch (ExceptionBaz $e) { + 23 echo "caught\n"; + 24 } + 25 + 26 echo "And do some more\n"; + 27 } + 28 + 29 trycatch(1); + 30 trycatch(2); + 31 try { + 32 trycatch(3); + 33 } catch ( Exception $e ) { + 34 echo "CAUGHT IN MAIN\n"; + 35 } + 36 ?>]]> +</example> + +</slide> diff --git a/slides/xdebug/vld-path-2-code.xml b/slides/xdebug/vld-path-2-code.xml new file mode 100644 index 0000000..c6b2a6e --- /dev/null +++ b/slides/xdebug/vld-path-2-code.xml @@ -0,0 +1,31 @@ +<slide> +<title>vld paths #2: code</title> + +<example> +<![CDATA[<?php +function loopy($i) +{ + do + { + echo $i, ' '; + + } while( $i-- ); + echo "\n"; +} + +function ifthenelse( $a, $b ) +{ + if ($a) { + echo "A HIT\n"; + } + if ($b) { + echo "B HIT\n"; + } +} + +loopy(0); +ifthenelse( true, false ); +ifthenelse( false, true ); +?>]]> +</example> +</slide> diff --git a/slides/xdebug/vld-path-2-output.xml b/slides/xdebug/vld-path-2-output.xml new file mode 100644 index 0000000..b6e0bd9 --- /dev/null +++ b/slides/xdebug/vld-path-2-output.xml @@ -0,0 +1,41 @@ +<slide> +<title>vld paths #2: output</title> + +<example> +<![CDATA[ +Function ifthenelse: +filename: /home/derick/dev/php/derickr-xdebug/tests/bug01034-004.inc +function name: ifthenelse +number of ops: 15 +compiled vars: !0 = $a, !1 = $b +line #* E I O op fetch ext return operands +------------------------------------------------------------------------------------- + 12 0 E > EXT_NOP + 1 RECV !0 + 2 RECV !1 + 14 3 EXT_STMT + 4 > JMPZ !0, ->8 + 15 5 > EXT_STMT + 6 ECHO 'A+HIT%0A' + 16 7 > JMP ->8 + 17 8 > EXT_STMT + 9 > JMPZ !1, ->13 + 18 10 > EXT_STMT + 11 ECHO 'B+HIT%0A' + 19 12 > JMP ->13 + 20 13 > EXT_STMT + 14 > RETURN null + +branch: # 0; line: 12- 14; sop: 0; eop: 4; out1: 5; out2: 8 +branch: # 5; line: 15- 16; sop: 5; eop: 7; out1: 8 +branch: # 8; line: 17- 17; sop: 8; eop: 9; out1: 10; out2: 13 +branch: # 10; line: 18- 19; sop: 10; eop: 12; out1: 13 +branch: # 13; line: 20- 20; sop: 13; eop: 14; out1: -2 +path #1: 0, 5, 8, 10, 13, +path #2: 0, 5, 8, 13, +path #3: 0, 8, 10, 13, +path #4: 0, 8, 13, +End of function ifthenelse +]]> +</example> +</slide> diff --git a/slides/xdebug/vld-path-2-paths.png b/slides/xdebug/vld-path-2-paths.png new file mode 100644 index 0000000..13d481b Binary files /dev/null and b/slides/xdebug/vld-path-2-paths.png differ diff --git a/slides/xdebug/vld-path-2-paths.xml b/slides/xdebug/vld-path-2-paths.xml new file mode 100644 index 0000000..bada25b --- /dev/null +++ b/slides/xdebug/vld-path-2-paths.xml @@ -0,0 +1,32 @@ +<slide> + +<image align="right" filename="vld-path-2-paths.png"/> +<example> +<![CDATA[ 1 <?php + 2 function loopy($i) + 3 { + 4 do + 5 { + 6 echo $i, ' '; + 7 + 8 } while( $i-- ); + 9 echo "\n"; + 10 } + 11 + 12 function ifthenelse( $a, $b ) + 13 { + 14 if ($a) { + 15 echo "A HIT\n"; + 16 } + 17 if ($b) { + 18 echo "B HIT\n"; + 19 } + 20 } + 21 + 22 loopy(0); + 23 ifthenelse( true, false ); + 24 ifthenelse( false, true ); + 25 ?>]]> +</example> + +</slide> diff --git a/slides/xdebug/vld-path-3-code.xml b/slides/xdebug/vld-path-3-code.xml new file mode 100644 index 0000000..efb9530 --- /dev/null +++ b/slides/xdebug/vld-path-3-code.xml @@ -0,0 +1,24 @@ +<slide> +<title>Xdebug code coverage</title> + +<example> +<![CDATA[ +--TEST-- +Test for bug #1034: path coverage +--FILE-- +<?php +include 'dump-branch-coverage.inc'; + +xdebug_start_code_coverage(XDEBUG_CC_UNUSED | XDEBUG_CC_DEAD_CODE | XDEBUG_CC_BRANCH_CHECK); + +include 'bug01034-004.inc'; + +xdebug_stop_code_coverage(false); +$c = xdebug_get_code_coverage(); +dump_branch_coverage($c); +?> +--EXPECTF-- +… +]]> +</example> +</slide> diff --git a/slides/xdebug/vld-path-3-output.xml b/slides/xdebug/vld-path-3-output.xml new file mode 100644 index 0000000..8662824 --- /dev/null +++ b/slides/xdebug/vld-path-3-output.xml @@ -0,0 +1,27 @@ +<slide> +<title>Xdebug code output</title> + +<example> +ifthenelse +- branches + - 00; OP: 00-04; line: 12-14 HIT; out1: 05 HIT; out2: 08 HIT + - 05; OP: 05-07; line: 15-16 HIT; out1: 08 HIT + - 08; OP: 08-09; line: 17-17 HIT; out1: 10 HIT; out2: 13 HIT + - 10; OP: 10-12; line: 18-19 HIT; out1: 13 HIT + - 13; OP: 13-14; line: 20-20 HIT; out1: EX X +- paths + - 0 5 8 10 13: X + - 0 5 8 13: HIT + - 0 8 10 13: HIT + - 0 8 13: X + +loopy +- branches + - 00; OP: 00-02; line: 02-06 HIT; out1: 03 HIT + - 03; OP: 03-07; line: 06-08 HIT; out1: 08 HIT; out2: 03 X + - 08; OP: 08-11; line: 09-10 HIT; out1: EX X +- paths + - 0 3 8: HIT + - 0 3 3 8: X +</example> +</slide> diff --git a/slides/xdebug/vld-path-3-paths.png b/slides/xdebug/vld-path-3-paths.png new file mode 100644 index 0000000..ed692c5 Binary files /dev/null and b/slides/xdebug/vld-path-3-paths.png differ diff --git a/slides/xdebug/vld-path-3-paths.xml b/slides/xdebug/vld-path-3-paths.xml new file mode 100644 index 0000000..a0fbc6a --- /dev/null +++ b/slides/xdebug/vld-path-3-paths.xml @@ -0,0 +1,32 @@ +<slide> + +<image align="right" filename="vld-path-3-paths.png"/> +<example> +<![CDATA[<?php +function loopy($i) +{ + do + { + echo $i, ' '; + + } while( $i-- ); + echo "\n"; +} + +function ifthenelse( $a, $b ) +{ + if ($a) { + echo "A HIT\n"; + } + if ($b) { + echo "B HIT\n"; + } +} + +loopy(0); +ifthenelse( true, false ); +ifthenelse( false, true ); +?>]]> +</example> + +</slide> diff --git a/slides/xdebug/xdebug-var-dump.xml b/slides/xdebug/xdebug-var-dump.xml index 90c97da..cccceb3 100644 --- a/slides/xdebug/xdebug-var-dump.xml +++ b/slides/xdebug/xdebug-var-dump.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="ISO-8859-1"?> -<slide fontsize="6em"> +<slide fontsize="6em" style="past"> <title>Pretty Printing Variables</title> <div effect="fade-out"> diff --git a/templates/default/slide.ezt b/templates/default/slide.ezt index 875377b..6580b7f 100644 --- a/templates/default/slide.ezt +++ b/templates/default/slide.ezt @@ -1,4 +1,5 @@ {use $node, $pres, $slideNr, $css = array("core.css")} +{var $style = get_attribute( $node, 'style' )} <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> @@ -8,6 +9,9 @@ {foreach $css as $cssFile} <link type="text/css" rel="stylesheet" href="/{$cssFile}"/> {/foreach} +{if $style} + <link type="text/css" rel="stylesheet" href="/style-{$style}.css"/> +{/if} <!--[if lt IE 8]> <script src="IE8.js" type="text/javascript"></script> <![endif]--> diff --git a/xdebug-phpnw14.xml b/xdebug-phpnw14.xml new file mode 100644 index 0000000..a25f2cc --- /dev/null +++ b/xdebug-phpnw14.xml @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="10gen-strict.css"> +<topic>Debugging</topic> +<title>Debugging: Past, Present and Future</title> +<event>PHP NorthWest 2014</event> +<location>Manchester, UK</location> +<date>October 4th, 2014</date> +<speaker>Derick Rethans</speaker> +<email>derick@mongodb.com</email> +<twitter>derickr</twitter> +<url>http://derickrethans.nl/talks.html</url> +<joindin>http://joind.in/11790</joindin> +<slide>slides/mongodb/title.xml</slide> +<slide>slides/toolbox/me.xml</slide> + +<slide>slides/xdebug/agenda-ppp.xml</slide> +<slide>slides/xdebug/xdebug-var-dump.xml</slide> +<slide>slides/xdebug/library-ladybug.xml</slide> +<slide>slides/xdebug/library-krumo.xml</slide> +<slide>slides/xdebug/library-kint.xml</slide> +<slide>slides/xdebug/library-symfony.xml</slide> +<slide>slides/xdebug/cli-color.xml</slide> +<slide>slides/xdebug/shutup.xml</slide> + +<slide>slides/xdebug/tracing.xml</slide> +<slide>slides/xdebug/functiontrace-summary.xml</slide> + +<slide>slides/xdebug/analyse-running-script.xml</slide> +<slide>slides/xdebug/netbeans.xml</slide> +<slide>slides/xdebug/komodo.xml</slide> +<slide>slides/xdebug/phpstorm.xml</slide> +<slide>slides/xdebug/debugger-activation.xml</slide> +<slide>slides/xdebug/debugger-browser-extensions.xml</slide> +<slide>slides/xdebug/debugger-connection-log.xml</slide> + +<slide>slides/xdebug/phpdbg.xml</slide> +<slide>slides/xdebug/phpdbg-demo.xml</slide> + +<slide>slides/internals/vld2.xml</slide> + +<slide>slides/xdebug/vld-path-1-code.xml</slide> +<slide>slides/xdebug/vld-path-1-output.xml</slide> +<slide>slides/xdebug/vld-path-1-paths.xml</slide> +<slide>slides/xdebug/vld-path-2-code.xml</slide> +<slide>slides/xdebug/vld-path-2-output.xml</slide> +<slide>slides/xdebug/vld-path-2-paths.xml</slide> +<slide>slides/xdebug/vld-path-3-code.xml</slide> +<slide>slides/xdebug/vld-path-3-output.xml</slide> +<slide>slides/xdebug/vld-path-3-paths.xml</slide> + +<slide>slides/xdebug/restaurant.xml</slide> + +<slide>slides/xdebug/resources.xml</slide> + +</presentation>
« previous php.pres (#2004) next »