X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=gdb%2Ftestsuite%2Fgdb.base%2Fhelp.exp;h=ac646e72e57e66f163867e38de56733c678e0f95;hb=dbf6a605eef9bd4ab5aaaa010de58baa025fb09b;hp=508728b3f2858af59eeb6481c75fa1b7e832318d;hpb=9b254dd1ce46c19dde1dde5b8d1e22e862dfacce;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/testsuite/gdb.base/help.exp b/gdb/testsuite/gdb.base/help.exp index 508728b3f2..ac646e72e5 100644 --- a/gdb/testsuite/gdb.base/help.exp +++ b/gdb/testsuite/gdb.base/help.exp @@ -1,5 +1,5 @@ -# Copyright 1988, 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# Copyright 1988, 1990-1992, 1994-2000, 2002-2003, 2005-2012 Free +# Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -14,22 +14,17 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Please email any bugs, comments, and/or additions to this file to: -# bug-gdb@prep.ai.mit.edu - # This file was written by Rob Savoye. (rob@cygnus.com) # # test gdb help commands # -set prms_id 0 -set bug_id 0 gdb_start -# force the height of the debugger to be pretty large so no pagers getused -gdb_test "set height 400" "" "test set height" +# force the height of the debugger to be pretty large so no pagers get used +gdb_test_no_output "set height 500" "test set height" # use a larger expect input buffer for long help outputs. # test help add-symbol-file @@ -42,22 +37,22 @@ test_class_help "aliases" {"Aliases of other commands\.\[\r\n\]+"} # test help append gdb_test "help append" "Append target code/data to a local file\.\[\r\n\]+List of append subcommands:.*" gdb_test "help append binary" "Append target code/data to a raw binary file\.\[\r\n\]+List of append binary subcommands:.*" -gdb_test "help append memory" "Append contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specifed FILE in raw target ordered bytes\." +gdb_test "help append memory" "Append contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specified FILE in raw target ordered bytes\." gdb_test "help append value" "Append the value of an expression to a raw binary file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION to\[\r\n\]+the specified FILE in raw target ordered bytes\." -gdb_test "help append binary memory" "Append contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specifed FILE in raw target ordered bytes\." +gdb_test "help append binary memory" "Append contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specified FILE in raw target ordered bytes\." gdb_test "help append binary value" "Append the value of an expression to a raw binary file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION\[\r\n\]+to the specified FILE in raw target ordered bytes\." # test help attach gdb_test "help attach" "Attach to a process or file outside of GDB\.\[\r\n\]+This command attaches to another target, of the same type as your last\[\r\n\]+\"target\" command \\(\"info files\" will show your target stack\\)\.\[\r\n\]+The command may take as argument a process id or a device file\.\[\r\n\]+For a process id, you must have permission to send the process a signal,\[\r\n\]+and it must have the same effective uid as the debugger\.\[\r\n\]+When using \"attach\" with a process id, the debugger finds the\[\r\n\]+program running in the process, looking first in the current working\[\r\n\]+directory, or \\(if not found there\\) using the source file search path\[\r\n\]+\\(see the \"directory\" command\\)\. You can also use the \"file\" command\[\r\n\]+to specify the program, and to load its symbol table\." "help attach" # test help breakpoint "b" abbreviation -gdb_test "help b" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of selected stack frame\.\[\r\n\]+This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if conditional\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"b\" abbreviation" +gdb_test "help b" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[PROBE_MODIFIER\] \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+PROBE_MODIFIER shall be present if the command is to be placed in a\[\r\n\]+probe point\. Accepted values are \\`-probe\\' \\(for a generic, automatically\[\r\n\]+guessed probe type\\) or \\`-probe-stap\\' \\(for a SystemTap probe\\)\.\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of the selected\[\r\n\]+stack frame\. This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if their\[\r\n\]+conditions are different\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"b\" abbreviation" # test help breakpoint "br" abbreviation -gdb_test "help br" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of selected stack frame\.\[\r\n\]+This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if conditional\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"br\" abbreviation" +gdb_test "help br" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[PROBE_MODIFIER\] \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+PROBE_MODIFIER shall be present if the command is to be placed in a\[\r\n\]+probe point\. Accepted values are \\`-probe\\' \\(for a generic, automatically\[\r\n\]+guessed probe type\\) or \\`-probe-stap\\' \\(for a SystemTap probe\\)\.\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of the selected\[\r\n\]+stack frame\. This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if their\[\r\n\]+conditions are different\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"br\" abbreviation" # test help breakpoint "bre" abbreviation -gdb_test "help bre" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of selected stack frame\.\[\r\n\]+This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if conditional\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"bre\" abbreviation" +gdb_test "help bre" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[PROBE_MODIFIER\] \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+PROBE_MODIFIER shall be present if the command is to be placed in a\[\r\n\]+probe point\. Accepted values are \\`-probe\\' \\(for a generic, automatically\[\r\n\]+guessed probe type\\) or \\`-probe-stap\\' \\(for a SystemTap probe\\)\.\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of the selected\[\r\n\]+stack frame\. This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if their\[\r\n\]+conditions are different\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"bre\" abbreviation" # test help breakpoint "brea" abbreviation -gdb_test "help brea" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of selected stack frame\.\[\r\n\]+This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if conditional\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"brea\" abbreviation" +gdb_test "help brea" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[PROBE_MODIFIER\] \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+PROBE_MODIFIER shall be present if the command is to be placed in a\[\r\n\]+probe point\. Accepted values are \\`-probe\\' \\(for a generic, automatically\[\r\n\]+guessed probe type\\) or \\`-probe-stap\\' \\(for a SystemTap probe\\)\.\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of the selected\[\r\n\]+stack frame\. This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if their\[\r\n\]+conditions are different\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"brea\" abbreviation" # test help breakpoint "break" abbreviation -gdb_test "help break" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of selected stack frame\.\[\r\n\]+This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if conditional\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"break\" abbreviation" +gdb_test "help break" "Set breakpoint at specified line or function\.\[\r\n\]+break \\\[PROBE_MODIFIER\] \\\[LOCATION\] \\\[thread THREADNUM\] \\\[if CONDITION\]\[\r\n\]+PROBE_MODIFIER shall be present if the command is to be placed in a\[\r\n\]+probe point\. Accepted values are \\`-probe\\' \\(for a generic, automatically\[\r\n\]+guessed probe type\\) or \\`-probe-stap\\' \\(for a SystemTap probe\\)\.\[\r\n\]+LOCATION may be a line number, function name, or \"\[*\]\" and an address\.\[\r\n\]+If a line number is specified, break at start of code for that line\.\[\r\n\]+If a function is specified, break at start of code for that function\.\[\r\n\]+If an address is specified, break at that exact address\.\[\r\n\]+With no LOCATION, uses current execution address of the selected\[\r\n\]+stack frame\. This is useful for breaking on return to a stack frame\.\[\r\n\]+THREADNUM is the number from \"info threads\"\.\[\r\n\]+CONDITION is a boolean expression\.\[\r\n\]+Multiple breakpoints at one place are permitted, and useful if their\[\r\n\]+conditions are different\.\[\r\n\]+Do \"help breakpoints\" for info on other commands dealing with breakpoints\." "help breakpoint \"break\" abbreviation" # test help breakpoints test_class_help "breakpoints" {"Making program stop at certain points\.\[\r\n\]+"} # test help backtrace "bt" abbreviation @@ -71,7 +66,7 @@ gdb_test "help continue" "Continue program being debugged.*" "help continue" # test help call gdb_test "help call" "Call a function.*" "help call" # test help catch -gdb_test "help catch" "Set catchpoints to catch events.*Raised signals may be caught:.*catch signal.*all signals.*catch signal.*signame.*a particular signal.*Raised exceptions may be caught:.*catch throw.*all exceptions, when thrown.*catch throw.*exceptname.*a particular exception, when thrown.*catch catch.*all exceptions, when caught.*catch catch.*exceptname.*a particular exception, when caught.*Thread or process events may be caught:.*catch thread_start.*any threads, just after creation.*catch thread_exit.*any threads, just before expiration.*catch thread_join.*any threads, just after joins.*catch start.*any processes, just after creation.*catch exit.*any processes, just before expiration.*catch fork.*calls to fork.*catch vfork.*calls to vfork.*catch exec.*calls to exec.*Dynamically.linked library events may be caught:.*catch load.*loads of any library.*catch load.*libname.*loads of a particular library.*catch unload.*unloads of any library.*catch unload.*libname.*unloads of a particular library.*The act of your program's execution stopping may also be caught:.*catch stop.*Do.*help set follow-fork-mode.*for info on debugging your program.*after a fork or vfork is caught.*Do.*help breakpoints.*for info on other commands dealing with breakpoints." "help catch" +gdb_test "help catch" "Set catchpoints to catch events.*List of catch subcommands:.*catch assert -- Catch failed Ada assertions.*catch catch -- Catch an exception.*catch exception -- Catch Ada exceptions.*catch exec -- Catch calls to exec.*catch fork -- Catch calls to fork.*catch vfork -- Catch calls to vfork.*Type .help catch. followed by catch subcommand name for full documentation.*Type .apropos word. to search for commands related to .word..*Command name abbreviations are allowed if unambiguous.*" "help catch" # test help cd gdb_test "help cd" "Set working directory to DIR for debugger and program being debugged\.\[\r\n\]+The change does not take effect for the program being debugged\[\r\n\]+until the next time it is started\." "help cd" # test help clear @@ -114,7 +109,7 @@ set expected_help_disable { "Disable some breakpoints\.\[\r\n\]+" "Arguments are breakpoint numbers with spaces in between\.\[\r\n\]+" "To disable all breakpoints, give no argument\.\[\r\n\]+" - "A disabled breakpoint is not forgotten, but has no effect until reenabled\.\[\r\n\]+" + "A disabled breakpoint is not forgotten, but has no effect until re-enabled\.\[\r\n\]+" } test_prefix_command_help {"dis" "disable"} $expected_help_disable "help disable \"dis\" abbreviation" # test help disable "disa" abbreviation @@ -122,11 +117,11 @@ test_prefix_command_help {"disa" "disable"} $expected_help_disable "help disable # test help disable test_prefix_command_help "disable" $expected_help_disable # test help disable breakpoints -gdb_test "help disable breakpoints" "Disable some breakpoints\.\[\r\n\]+Arguments are breakpoint numbers with spaces in between\.\[\r\n\]+To disable all breakpoints, give no argument\.\[\r\n\]+A disabled breakpoint is not forgotten, but has no effect until reenabled\.\[\r\n\]+This command may be abbreviated \"disable\"." "help disable breakpoints" +gdb_test "help disable breakpoints" "Disable some breakpoints\.\[\r\n\]+Arguments are breakpoint numbers with spaces in between\.\[\r\n\]+To disable all breakpoints, give no argument\.\[\r\n\]+A disabled breakpoint is not forgotten, but has no effect until re-enabled\.\[\r\n\]+This command may be abbreviated \"disable\"." "help disable breakpoints" # test help disable display gdb_test "help disable display" "Disable some expressions to be displayed when program stops\.\[\r\n\]+Arguments are the code numbers of the expressions to stop displaying\.\[\r\n\]+No argument means disable all automatic-display expressions\.\[\r\n\]+Do \"info display\" to see current list of code numbers\." "help disable display" # test help disassemble -gdb_test "help disassemble" "Disassemble a specified section of memory\.\[\r\n\]+Default is the function surrounding the pc of the selected frame\.\[\r\n\]+With a single argument, the function surrounding that address is dumped\.\[\r\n\]+Two arguments are taken as a range of memory to dump\." "help disassemble" +gdb_test "help disassemble" "Disassemble a specified section of memory\.\[\r\n\]+Default is the function surrounding the pc of the selected frame\.\[\r\n\]+With a /m modifier, source lines are included \\(if available\\)\.\[\r\n\]+With a /r modifier, raw instructions in hex are included\.\[\r\n\]+With a single argument, the function surrounding that address is dumped\.\[\r\n\]+Two arguments \\(separated by a comma\\) are taken as a range of memory to dump,\[\r\n\]+ in the form of \"start,end\", or \"start,\\+length\"\." "help disassemble" # test help display gdb_test "help display" "Print value of expression EXP each time the program stops\.\[\r\n\]+/FMT may be used before EXP as in the \"print\" command\.\[\r\n\]+/FMT \"i\" or \"s\" or including a size-letter is allowed,\[\r\n\]+as in the \"x\" command, and then EXP is used to get the address to examine\[\r\n\]+and examining is done as in the \"x\" command\.\[\r\n\]+With no argument, display all currently requested auto-display expressions\.\[\r\n\]+Use \"undisplay\" to cancel display requests previously made\." "help display" # test help do @@ -141,17 +136,17 @@ gdb_test "help down-silently" "Same as the `down' command, but does not print an gdb_test "help dump" "Dump target code/data to a local file\.\[\r\n\]+List of dump subcommands:.*" gdb_test "help dump binary" "Write target code/data to a raw binary file\.\[\r\n\]+List of dump binary subcommands:.*" gdb_test "help dump ihex" "Write target code/data to an intel hex file\.\[\r\n\]+List of dump ihex subcommands:.*" -gdb_test "help dump memory" "Write contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specifed FILE in raw target ordered bytes\." +gdb_test "help dump memory" "Write contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within the\[\r\n\]+range \\\[START \.\. STOP\\) to the specified FILE in raw target ordered bytes\." gdb_test "help dump srec" "Write target code/data to an srec file\.\[\r\n\]+List of dump srec subcommands:.*" gdb_test "help dump tekhex" "Write target code/data to a tekhex file\.\[\r\n\]+List of dump tekhex subcommands:.*" gdb_test "help dump value" "Write the value of an expression to a raw binary file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION to\[\r\n\]+the specified FILE in raw target ordered bytes\." -gdb_test "help dump binary memory" "Write contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specifed FILE in binary format\." +gdb_test "help dump binary memory" "Write contents of memory to a raw binary file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specified FILE in binary format\." gdb_test "help dump binary value" "Write the value of an expression to a raw binary file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION\[\r\n\]+to the specified FILE in raw target ordered bytes\." "help dump binary value" -gdb_test "help dump ihex memory" "Write contents of memory to an ihex file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within\[\r\n\]+the range \\\[START \.\. STOP\\) to the specifed FILE in intel hex format\." +gdb_test "help dump ihex memory" "Write contents of memory to an ihex file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory within\[\r\n\]+the range \\\[START \.\. STOP\\) to the specified FILE in intel hex format\." gdb_test "help dump ihex value" "Write the value of an expression to an ihex file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION\[\r\n\]+to the specified FILE in intel hex format\." -gdb_test "help dump srec memory" "Write contents of memory to an srec file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specifed FILE in srec format\." +gdb_test "help dump srec memory" "Write contents of memory to an srec file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specified FILE in srec format\." gdb_test "help dump srec value" "Write the value of an expression to an srec file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION\[\r\n\]+to the specified FILE in srec format\." -gdb_test "help dump tekhex memory" "Write contents of memory to a tekhex file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specifed FILE in tekhex format\." +gdb_test "help dump tekhex memory" "Write contents of memory to a tekhex file\.\[\r\n\]+Arguments are FILE START STOP\. Writes the contents of memory\[\r\n\]+within the range \\\[START \.\. STOP\\) to the specified FILE in tekhex format\." gdb_test "help dump tekhex value" "Write the value of an expression to a tekhex file\.\[\r\n\]+Arguments are FILE EXPRESSION\. Writes the value of EXPRESSION\[\r\n\]+to the specified FILE in tekhex format\." # this command was removed from GDB 4.5.8 # test help dump-me @@ -199,29 +194,25 @@ gdb_test "help file" "Use FILE as program to be debugged\.\[\r\n\]+It is read fo # test help files gdb_test "help files" "Specifying.*" "help files" # test help finish -gdb_test "help finish" "Execute until selected stack frame returns\.\[\r\n\]+Upon return, the value returned is printed and put in the value history\." "help finish" +gdb_test "help finish" "Execute until selected stack frame returns\.\[\r\n\]+Usage: finish\[\r\n\]+Upon return, the value returned is printed and put in the value history\.\[\r\n\]+" "help finish" # test help forward-search gdb_test "help forward-search" "Search for regular expression \\(see regex\\(3\\)\\) from last line listed.*" "help forward-search" # test help gcore -send_gdb "help gcore\n" -gdb_expect { +gdb_test_multiple "help gcore" "help gcore" { -re "Undefined command: \"gcore\"\. Try \"help\".*$gdb_prompt $" { pass "help gcore" } -re "Save a core file with the current state of the debugged process\.\[\r\n\]+Argument is optional filename\. Default filename is 'core\.'.*$gdb_prompt $" { pass "help gcore" } - default { fail "help gcore" } } -send_gdb "help generate-core-file\n" -gdb_expect { +gdb_test_multiple "help generate-core-file" "help generate-core-file" { -re "Undefined command: \"generate-core-file\"\. Try \"help\".*$gdb_prompt $" { pass "help gcore" } -re "Save a core file with the current state of the debugged process\.\[\r\n\]+Argument is optional filename\. Default filename is 'core\.'.*$gdb_prompt $" { pass "help gcore" } - default { fail "help gcore" } } # test help help "h" abbreviation gdb_test "help h" "Print list of commands\." "help help \"h\" abbreviation" @@ -246,9 +237,9 @@ gdb_test "help info all-registers" "List of all registers and their contents, fo # test help info args gdb_test "help info args" "Argument variables of current stack frame\." "help info args" # test help info breakpoints -gdb_test "help info breakpoints" "Status of user-settable breakpoints, or breakpoint number NUMBER\..*\[\r\n\]+breakpoint set\." "help info breakpoints" -# test help info catch -gdb_test "help info catch" "Exceptions that can be caught in the current stack frame\." "help info catch" +gdb_test "help info breakpoints" \ + "Status of specified breakpoints .all user-settable breakpoints if no argument.*\[\r\n\]+breakpoint set\." \ + "help info breakpoints" # test help info copying gdb_test "help info copying" "Conditions for redistributing copies of GDB\." "help info copying" # test help info display @@ -289,6 +280,8 @@ gdb_test "help info symbol" "Describe what symbol is at location ADDR.*" gdb_test "help info target" "Names of targets and files being debugged\.\[\r\n\]+Shows the entire stack of targets currently in use \\(including the exec-file,\[\r\n\]+core-file, and process, if any\\), as well as the symbol file name\." "help info target" # test help info terminal gdb_test "help info terminal" "Print inferior's saved terminal status\." "help info terminal" +# test help info threads +gdb_test "help info threads" "Display currently known threads.*" "help info threads" # test help info types gdb_test "help info types" "All type names, or those matching REGEXP\." "help info types" # test help info variables @@ -296,13 +289,17 @@ gdb_test "help info variables" "All global and static variable names, or those m # test help info warranty gdb_test "help info warranty" "Various kinds of warranty you do not have\." "help info warranty" # test help info watchpoints -gdb_test "help info watchpoints" "Synonym for ``info breakpoints''\." "help info watchpoints" +gdb_test "help info watchpoints" \ + "Status of specified watchpoints .all watchpoints if no argument.\." \ + "help info watchpoints" # test help inspect gdb_test "help inspect" "Same as \"print\" command, except that if you are running in the epoch\[\r\n\]+environment, the value is printed in its own window\." "help inspect" # test help jump -gdb_test "help jump" "Continue program being debugged at specified line or address\.\[\r\n\]+Give as argument either LINENUM or \[*\]+ADDR, where ADDR is an expression\[\r\n\]+for an address to start at\." "help jump" +gdb_test "help jump" "Continue program being debugged at specified line or address\.\[\r\n\]+Usage: jump \[\r\n\]+Give as argument either LINENUM or \[*\]+ADDR, where ADDR is an expression\[\r\n\]+for an address to start at\." "help jump" # test help kill -gdb_test "help kill" "Kill execution of program being debugged\." "help kill" +test_prefix_command_help "kill" { + "Kill execution of program being debugged\.\[\r\n\]+" +} # test help list "l" abbreviation gdb_test "help l" "List specified function or line\.\[\r\n\]+With no argument, lists ten more lines after or around previous listing\.\[\r\n\]+\"list -\" lists the ten lines before a previous ten-line listing\.\[\r\n\]+One argument specifies a line, and ten lines are listed around that line\.\[\r\n\]+Two arguments with comma between specify starting and ending lines to list\.\[\r\n\]+Lines can be specified in these ways:\[\r\n\]+ LINENUM, to list around that line in current file,\[\r\n\]+ FILE:LINENUM, to list around that line in that file,\[\r\n\]+ FUNCTION, to list around beginning of that function,\[\r\n\]+ FILE:FUNCTION, to distinguish among like-named static functions\.\[\r\n\]+ \[*\]ADDRESS, to list around the line containing that address\.\[\r\n\]+With two args if one is empty it stands for ten lines away from the other arg\." "help list \"l\" abbreviation" # test help list @@ -312,11 +309,11 @@ gdb_test "help load" "Dynamically load FILE into the running program, and record # test help make gdb_test "help make" "Run the ``make'' program using the rest of the line as arguments\." "help make" # test help next "n" abbreviation -gdb_test "help n" "Step program, proceeding through subroutine calls\.\[\r\n\]+Like the \"step\" command as long as subroutine calls do not happen;\[\r\n\]+when they do, the call is treated as one instruction\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help next \"n\" abbreviation" +gdb_test "help n" "Step program, proceeding through subroutine calls\.\[\r\n\]+Usage: next \\\[N\\\]\[\r\n\]+Unlike \"step\", if the current source line calls a subroutine,\[\r\n\]+this command does not enter the subroutine, but instead steps over\[\r\n\]+the call, in effect treating it as a single source line\.\[\r\n\]+" "help next \"n\" abbreviation" # test help next -gdb_test "help next" "Step program, proceeding through subroutine calls\.\[\r\n\]+Like the \"step\" command as long as subroutine calls do not happen;\[\r\n\]+when they do, the call is treated as one instruction\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help next" +gdb_test "help next" "Step program, proceeding through subroutine calls\.\[\r\n\]+Usage: next \\\[N\\\]\[\r\n\]+Unlike \"step\", if the current source line calls a subroutine,\[\r\n\]+this command does not enter the subroutine, but instead steps over\[\r\n\]+the call, in effect treating it as a single source line\.\[\r\n\]+" "help next \"n\" abbreviation" # test help nexti -gdb_test "help ni" "Step one instruction, but proceed through subroutine calls\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help nexti" +gdb_test "help ni" "Step one instruction, but proceed through subroutine calls\.\[\r\n\]+Usage: nexti \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help nexti" # all the commands that used to be here are now in "maintainance" instead # test help obscure test_class_help "obscure" { @@ -368,9 +365,9 @@ test_class_help "running" { "Running the program\.\[\r\n\]+" } # test help step "s" abbreviation -gdb_test "help s" "Step program until it reaches a different source line\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help step \"s\" abbreviation" +gdb_test "help s" "Step program until it reaches a different source line\.\[\r\n\]+Usage: step \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help step \"s\" abbreviation" # test help step -gdb_test "help step" "Step program until it reaches a different source line\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help step #1" +gdb_test "help step" "Step program until it reaches a different source line\.\[\r\n\]+Usage: step \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help step #1" # test help search gdb_test "help search" "Search for regular expression \\(see regex\\(3\\)\\) from last line listed\..*" "help search" # test help section @@ -418,7 +415,8 @@ test_prefix_command_help {"set history"} { "Generic command for setting command history parameters\.\[\r\n\]+" } # test help set language -gdb_test "help set language" "Set the current source language\." "help set language" +gdb_test "help set language" "Set the current source language\.\[\r\n\]+The currently understood settings are:(\[^\r\n\]*\[\r\n\])+local or auto *Automatic setting based on source file(\[^\r\n\]*\[\r\n\])+c *Use the C language(\[^\r\n\]*\[\r\n\])+c\[+\]+ *Use the C\[+\]+ language(\[^\r\n\]*\[\r\n\])+modula-2 *Use the Modula-2 language.*" "help set language" + # test help set listsize gdb_test "help set listsize" "Set number of source lines gdb will list by default\." "help set listsize" # test help set print "p" abbreviation @@ -460,8 +458,6 @@ gdb_test "help set print vtbl" "Set printing of C\[+\]+ virtual function tables\ gdb_test "help set prompt" "Set gdb's prompt" "help set prompt" # test help set radix gdb_test "help set radix" "Set default input and output number radices\.\[\r\n\]+Use \'set input-radix\' or \'set output-radix\' to independently set each\.\[\r\n\]+Without an argument, sets both radices back to the default value of 10\." "help set radix" -# test help set symbol-reloading -gdb_test "help set symbol-reloading" "Set dynamic symbol table reloading multiple times in one run\." "help set symbol-reloading" # test help set variable gdb_test "help set variable" "Evaluate expression EXP and assign result to variable VAR, using assignment\[\r\n\]+syntax appropriate for the current language \\(VAR = EXP or VAR := EXP for\[\r\n\]+example\\)\. VAR may be a debugger \"convenience\" variable \\(names starting\[\r\n\]+with \\\$\\), a register \\(a few standard names starting with \\\$\\), or an actual\[\r\n\]+variable in the program being debugged\. EXP is any valid expression\.\[\r\n\]+This may usually be abbreviated to simply \"set\"\." "help set variable" # test help set verbose @@ -510,9 +506,9 @@ gdb_test "help show complaints" "Show max number of complaints about incorrect s # test help show confirm gdb_test "help show confirm" "Show whether to confirm potentially dangerous operations\." "help show confirm" # test help show convenience -gdb_test "help show convenience" "Debugger convenience \\(\"\\\$foo\"\\) variables\.\[\r\n\]+These variables are created when you assign them values;\[\r\n\]+thus, \"print \\\$foo=1\" gives \"\\\$foo\" the value 1\. Values may be any type\.\[\r\n\]+A few convenience variables are given values automatically:\[\r\n\]+\"\\\$_\"holds the last address examined with \"x\" or \"info lines\",\[\r\n\]+\"\\\$__\" holds the contents of the last address examined with \"x\"\." "help show convenience" +gdb_test "help show convenience" "Debugger convenience \\(\"\\\$foo\"\\) variables and functions\.\[\r\n\]+Convenience variables are created when you assign them values;\[\r\n\]+thus, \"set \\\$foo=1\" gives \"\\\$foo\" the value 1\. Values may be any type\.\[\r\n\]+A few convenience variables are given values automatically:\[\r\n\]+\"\\\$_\"holds the last address examined with \"x\" or \"info lines\",\[\r\n\]+\"\\\$__\" holds the contents of the last address examined with \"x\"\.\[\r\n\]+Convenience functions are defined via the Python API\." "help show convenience" # test help show directories -gdb_test "help show directories" "Current search path for finding source files\.\[\r\n\]+\\\$cwd in the path means the current working directory\.\[\r\n\]+\\\$cdir in the path means the compilation directory of the source file\." "help show directories" +gdb_test "help show directories" "Show the search path for finding source files\.\[\r\n\]+\\\$cwd in the path means the current working directory\.\[\r\n\]+\\\$cdir in the path means the compilation directory of the source file\..*" "help show directories" # test help show editing gdb_test "help show editing" "Show editing of command lines as they are typed\.\[\r\n\]+Use \"on\" to enable the editing, and \"off\" to disable it\.\[\r\n\]+Without an argument, command line editing is enabled\. To edit, use\[\r\n\]+EMACS-like or VI-like commands like control-P or ESC\." "help show editing" # test help show environment @@ -573,10 +569,8 @@ gdb_test "help show print vtbl" "Show printing of C\[+\]+ virtual function table gdb_test "help show prompt" "Show gdb's prompt" "help show prompt" # test help show radix gdb_test "help show radix" "Show the default input and output number radices\.\[\r\n\]+Use \'show input-radix\' or \'show output-radix\' to independently show each\." "help show radix" -# test help show symbol-reloading -gdb_test "help show symbol-reloading" "Show dynamic symbol table reloading multiple times in one run\." "help show symbol-reloading" # test help show user -gdb_test "help show user" "Show definitions of user defined commands\.\[\r\n\]+Argument is the name of the user defined command\.\[\r\n\]+With no argument, show definitions of all user defined commands\." "help show user" +gdb_test "help show user" "Show definitions of non-python user defined commands\.\[\r\n\]+Argument is the name of the user defined command\.\[\r\n\]+With no argument, show definitions of all user defined commands\." "help show user" # test help show values gdb_test "help show values" "Elements of value history around item number IDX \\(or last ten\\)\." "help show values" # test help show verbose @@ -596,16 +590,18 @@ test_prefix_command_help "show" { "Generic command for showing things about the debugger\.\[\r\n\]+" } # test help step -gdb_test "help step" "Step program until it reaches a different source line\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help step #2" +gdb_test "help step" "Step program until it reaches a different source line\.\[\r\n\]+Usage: step \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help step #2" # test help stepi "si" abbreviation -gdb_test "help si" "Step one instruction exactly\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help stepi \"si\" abbreviation" +gdb_test "help si" "Step one instruction exactly\.\[\r\n\]+Usage: stepi \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help stepi \"si\" abbreviation" # test help stepi -gdb_test "help stepi" "Step one instruction exactly\.\[\r\n\]+Argument N means do this N times \\(or till program stops for another reason\\)\." "help stepi" +gdb_test "help stepi" "Step one instruction exactly\.\[\r\n\]+Usage: stepi \\\[N\\\]\[\r\n\]+Argument N means step N times \\(or till program stops for another reason\\)\.\[\r\n\]+" "help stepi" # test help signal -gdb_test "help signal" "Continue program giving it signal.*" "help signal" +gdb_test "help signal" "Continue program with the specified signal.*" "help signal" # test help source # vxgdb reads .vxgdbinit -gdb_test "help source" "Read commands from a file named FILE\.\[\r\n\]+Optional -v switch \\(before the filename\\) causes each command in\[\r\n\]+FILE to be echoed as it is executed\.\[\r\n\]+Note that the file \"\[^\"\]*\" is read automatically in this way\[\r\n\]+when GDB is started\." "help source" +# ".-s. .-v." is written that way to avoid the complications of trying +# to get "[-s] [-v]" through expect and tcl. +gdb_test "help source" "Read commands from a file named FILE\.\[\r\n\]+Usage: source .-s. .-v. FILE\[\r\n\]+-s: search for the script in the source search path,\[\r\n\]+\[ \]+even if FILE contains directories\.\[\r\n\]+-v: each command in FILE is echoed as it is executed\.\[\r\n\]+Note that the file \"\[^\"\]*\" is read automatically in this way\[\r\n\]+when GDB is started\." "help source" # test help stack test_class_help "stack" { "Examining the stack\..*\[\r\n\]+" @@ -647,6 +643,14 @@ test_prefix_command_help "target" { } # test help tbreak gdb_test "help tbreak" "Set a temporary breakpoint.*" "help tbreak" +#test help thread +gdb_test "help thread" "Use this command to switch between threads.*" "help thread" +# test help thread apply +gdb_test "help thread apply" "Apply a command to a list of threads.*" "help thread apply" +# test help thread find +gdb_test "help thread find" "Find threads that match a regular.*" "help thread find" +# test help thread name +gdb_test "help thread name" "Set the current thread's name.*" "help thread name" # test help tty gdb_test "help tty" "Set terminal for future runs of program being debugged\.\[\r\n\]+Usage: set inferior-tty /dev/pts/1" "help tty" # test help until "u" abbreviation @@ -672,9 +676,9 @@ test_class_help "user-defined" { "Use the \"define\" command to define a command\.\[\r\n\]+" } # test help watch -gdb_test "help watch" "Set a watchpoint for an expression\.\[\r\n\]+A watchpoint stops execution of your program whenever the value of\[\r\n\]+an expression changes\." "help watch" +gdb_test "help watch" "Set a watchpoint for an expression\.\[\r\n\]+Usage: watch .-l.-location. EXPRESSION\[\r\n\]+A watchpoint stops execution of your program whenever the value of\[\r\n\]+an expression changes\.\[\r\n\]+If -l or -location is given, this evaluates EXPRESSION and watches\[\r\n\]+the memory to which it refers\." "help watch" # test help whatis -gdb_test "help whatis" "Print data type of expression EXP\." "help whatis" +gdb_test "help whatis" "Print data type of expression EXP\.\r\nOnly one level .*" "help whatis" # test help where gdb_test "help where" "Print backtrace of all stack frames, or innermost COUNT frames\.\[\r\n\]+With a negative argument, print outermost -COUNT frames\.\[\r\n\]+Use of the 'full' qualifier also prints the values of the local variables\." "help where" # test help x