aboutsummaryrefslogtreecommitdiff
path: root/cddl/contrib/opensolaris/cmd/dtrace/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Stop hard-coding a 32-bit data model for USDT tests, and just use the nativeMark Johnston2015-09-3020-21/+21
| | | | | | | | | | model. This was causing many of the tests to fail on amd64 since USDT support for 32-bit programs is currently non-functional. MFC after: 1 week Notes: svn path=/head/; revision=288413
* Don't hardcode the module or function component of lockstat probes.Mark Johnston2015-08-026-6/+6
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=286172
* - Remove hardcoded paths for the perl executable.Mark Johnston2015-08-026-7/+20
| | | | | | | | | | | | - Rather than assuming that a process is listening on 127.0.0.1:22, use nc(1) to find an available port and bind to it for the duration of the test. MFC after: 1 week Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=286171
* Fix ping(8) and ping6(8) usage in a couple of ip provider tests, andMark Johnston2015-03-304-16/+22
| | | | | | | | | | update expected test output to reflect differences in default TTL and payload length. MFC after: 1 week Notes: svn path=/head/; revision=280837
* Fix ping(8) usage in funcs/tst.system.d so that the test actually completes.Mark Johnston2015-03-302-6/+15
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=280836
* tcp provider tests: sleep for a bit after closing the socket so thatMark Johnston2015-03-284-0/+4
| | | | | | | | | libdtrace has a chance to capture the traced data. MFC after: 1 week Notes: svn path=/head/; revision=280773
* Use the -shared option to create a shared library.Mark Johnston2015-02-285-8/+8
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=279417
* Remove a leading tab that causes a make(1) error when running the test.Mark Johnston2015-02-281-1/+1
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=279416
* Only kill sleep processes that were forked from the test script.Mark Johnston2015-02-281-1/+1
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=279415
* Stop hard-coding an incorrect path to rm(1).Mark Johnston2015-02-285-5/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=279414
* Tweak the fds test program so that it actually compiles. Also use 0 insteadMark Johnston2015-02-142-7/+8
| | | | | | | | | | of -1 for the bogus ioctl command so that dmesg doesn't get spammed with sign extension warnings when the test program runs. MFC after: 1 week Notes: svn path=/head/; revision=278738
* Avoid hard-coding a path to ksh in scripts that are executed directly byMark Johnston2015-02-0311-11/+11
| | | | | | | | | | | the test harness. This is a problem in many of the *.ksh test scripts as well, but those scripts are executed using a shell whose path is specified in dtest.pl, so there's no need to modify them. MFC after: 1 week Notes: svn path=/head/; revision=278139
* Fix mktemp(1) usage.Mark Johnston2015-01-311-1/+1
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=278012
* Use syscall::exit instead of the nonexistent syscall::rexit.Mark Johnston2015-01-311-1/+1
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=278011
* Remove hard-coded invocations of gcc; use cc(1) instead.Mark Johnston2015-01-314-13/+7
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=278009
* Remove a makefile that isn't present upstream.Mark Johnston2015-01-311-13/+0
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=278008
* Fix a number of DTrace scripting tests:Mark Johnston2015-01-3111-27/+27
| | | | | | | | | | | * Avoid hard-coding program paths. * Use -x when searching for oneself in ps(1) output. * Use the correct keyword (egid instead of pgid) in tst.egid.ksh. MFC after: 1 week Notes: svn path=/head/; revision=278007
* Fix some proc provider tests:Mark Johnston2015-01-313-12/+14
| | | | | | | | | | | | | * Avoid hard-coding program paths, except when it's necessary in order to override the use of a shell builtin. * Translate struct proc through psinfo_t so that we can access process arguments via the pr_psargs field of psinfo_t. * Replace uses of pstop and prun with kill(1). MFC after: 1 week Notes: svn path=/head/; revision=278006
* pause() isn't a system call on FreeBSD; use sigsuspend(2) instead.Mark Johnston2015-01-301-2/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=277916
* The DTrace harness (dtest.pl) executes DTrace scripts with the -C flag,Mark Johnston2015-01-303-3/+9
| | | | | | | | | | | which causes dtrace(1) to run the C preprocessor on input scripts before executing them. Suppress some warnings emitted by the preprocessor which are confusing the DTrace lexer tests. MFC after: 1 week Notes: svn path=/head/; revision=277913
* Include required headers in DTrace test programs.Mark Johnston2015-01-3010-0/+15
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=277912
* Replace Solaris identifiers and types with their FreeBSD equivalents.Mark Johnston2015-01-3012-16/+16
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=277911
* Use the correct field when reading the PID out of a struct proc.Mark Johnston2015-01-304-4/+4
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=277910
* When searching for an accompanying test program, look in the directoryMark Johnston2015-01-301-1/+1
| | | | | | | | | | containing the test script rather than the current directory. This is needed in order to run the DTrace tests under Kyua. MFC after: 1 week Notes: svn path=/head/; revision=277909
* Remove a build artifact of the USDT tests.Mark Johnston2014-10-151-11/+0
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=273115
* Hook up support for userland CTF support in DTrace. This required someMark Johnston2014-10-031-1/+1
| | | | | | | | | | | | | | | | | | | | | modifications to libproc to support fetching the CTF info for a given file. With this change, dtrace(1) is able to resolve type info for function and USDT probe arguments, and function return values. In particular, the args[n] syntax should now work for referencing arguments of userland probes, provided that the requisite CTF info is available. The uctf tests pass if the test programs are compiled with CTF info. The current infrastructure around the DTrace test suite doesn't support this yet. Differential Revision: https://reviews.freebsd.org/D891 MFC after: 1 month Relnotes: yes Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=272488
* Implement a workaround to allow this test program to be compiled with clang.Mark Johnston2014-09-171-2/+2
| | | | | | | | | | | | It seems that if a pragma is used to define a weak alias for a local function, the pragma must appear after the function is defined. PR: 193056 MFC after: 1 week Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=271699
* Fix a number of typos and programming errors in the userland CTF tests. ItMark Johnston2014-09-174-5/+9
| | | | | | | | | | | seems that they would only pass by chance on illumos; on FreeBSD, they still fail since userland CTF is not yet supported. MFC after: 1 week Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=271698
* Fix elfdump(1) usage in the userland CTF tests.Mark Johnston2014-09-1610-10/+10
| | | | | | | | | PR: 193110 MFC after: 1 week Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=271693
* MFV illumosRui Paulo2014-06-2612-0/+1554
| | | | | | | | | | | 4471 DTrace count() with histogram 4472 DTrace full width distribution histograms 4473 DTrace frequency trails MFC after: 2 weeks Notes: svn path=/head/; revision=267942
* MFV illumosRui Paulo2014-06-2624-0/+1118
| | | | | | | | | | | | | 4474 DTrace Userland CTF Support 4475 DTrace userland Keyword 4476 DTrace tests should be better citizens 4479 pid provider types 4480 dof emulation is missing checks MFC after: 2 weeks Notes: svn path=/head/; revision=267941
* MFV illumosRui Paulo2014-06-2614-2/+790
| | | | | | | | | 4477 DTrace should speak JSON MFC after: 2 weeks Notes: svn path=/head/; revision=267937
* MFV illumos r266986:Rui Paulo2014-06-265-0/+454
| | | | | | | | | | | 2915 DTrace in a zone should see "cpu", "curpsinfo", et al 2916 DTrace in a zone should be able to access fds[] 2917 DTrace in a zone should have limited provider access MFC after: 2 weeks Notes: svn path=/head/; revision=267929
* Revert r267898.Rui Paulo2014-06-2612-1552/+0
| | | | Notes: svn path=/head/; revision=267925
* Bring the following change from the illumos-joyent repository:Rui Paulo2014-06-2612-0/+1552
| | | | | | | | | | | | | | | commit 78e24ab6803bbe11ba37642624e1498ede5b239d Author: Bryan Cantrill <bryan@joyent.com> Date: Thu Oct 31 01:20:54 2013 OS-1688 DTrace count() with histogram OS-2360 DTrace full width distribution histograms OS-2361 DTrace frequency trails MFC after: 2 weeks Notes: svn path=/head/; revision=267898
* MFV r266988:Pedro F. Giffuni2014-06-153-0/+168
| | | | | | | | | | | | | | Merge from r258379 missed the tests. 4248 dtrace(1M) should never create DOF with empty probes section 4249 Only probes from the first DTrace object file will be included Illumos Revision: 54a20ab41aadcb81c53e72fc65886e964e9add59 MFC after: 5 days Notes: svn path=/head/; revision=267513
* Fix tst.ZeroModuleProbes.d.ksh, which was incorrectly modified in r178534.Mark Johnston2014-05-191-1/+1
| | | | | | | | | Since "BEGIN" is not the name of a module, the test would just hang. MFC after: 3 days Notes: svn path=/head/; revision=266454
* Replace a few Solarisisms with their corresponding FreeBSDisms to make a fewMark Johnston2014-04-156-6/+6
| | | | | | | printf tests pass. Notes: svn path=/head/; revision=264487
* 4478 dtrace_dof_maxsize is far too smallMark Johnston2014-02-281-0/+97
| | | | | | | | | | illumos/illumos-gate@d339a29bb4765c4b6883a935cf69b669cd05bca0 PR: 187027 MFC after: 1 week Notes: svn path=/head/; revision=262596
* 1452 DTrace buffer autoscaling should be less violentMark Johnston2014-02-222-16/+0
| | | | | | | | | | | | | | illumos/illumos-gate@6fb4854bed54ce82bd8610896b64ddebcd4af706 This fixes the tst.resize1.d and tst.resize2.d DTrace tests, which have been failing since r261122 since they were causing dtrace(1) to attempt to allocate and use large amounts of memory, and get killed by the OOM killer as a result. MFC after: 1 month Notes: svn path=/head/; revision=262330
* Enable some previously-disabled DTrace tests for umod, ufunc and usym. TheyMark Johnston2013-12-043-3/+3
| | | | | | | | | expect the installed ksh binary to be named "ksh", which is not the case when it's installed on FreeBSD via the shells/ksh93 port. Allow for it to be "ksh93" as well so that the tests can actually pass. Notes: svn path=/head/; revision=258903
* DTrace: re-apply r249426 now that the underlying issues have been solved.Pedro F. Giffuni2013-07-2814-18/+151
| | | | | | | | | | | | | | | | | | | | | | | Merge change from illumos: 3519 DTrace fails to resolve const types from fbt 3520 dtrace internal error -- token type 316 is not a valid D compilation token 3521 clean up dtrace unit tests Illumos Revision: e98f46c Reference: https://www.illumos.org/issues/3519 https://www.illumos.org/issues/3520 https://www.illumos.org/issues/3521 Tested by: Fabian Keil Obtained from: Illumos MFC after: 1 month Notes: svn path=/head/; revision=253726
* DTrace: re-merge remainder of r249367 (original from Illumos).Pedro F. Giffuni2013-07-2824-149/+509
| | | | | | | | | | | | | | | | | | | | | | | | | | Bring back some important fixes from Illumos: 3022 DTrace: keys should not affect the sort order when sorting by value 3023 it should be possible to dereference dynamic variables 3024 D integer narrowing needs some work We particularly avoid the LD_NOLAZYLOAD changes that Illumos made as those don't apply to FreeBSD and were causing problems in interactive mode. Illumos Revision: 13758:23432da34147 Reference: https://www.illumos.org/issues/3022 https://www.illumos.org/issues/3023 https://www.illumos.org/issues/3024 MFC after: 1 month Tested by: markj Notes: svn path=/head/; revision=253725
* Use kern_ioctl() rather than ioctl() for testing the FBT provider, since theMark Johnston2013-07-277-12/+12
| | | | | | | latter doesn't exist in FreeBSD. All the tests under fbtprovider pass now. Notes: svn path=/head/; revision=253720
* Port the SDT test now that it's possible to create SDT probes that takeMark Johnston2013-06-022-13/+11
| | | | | | | | | | | | | | | seven arguments. The original test uses Solaris' uadmin system call to trigger the test probe; this change adds a sysctl to the dtrace_test module and gets the test program to trigger the test probe via the sysctl handler. The test is currently failing on amd64 because of some bugs in the way that probe arguments beyond the first five are obtained - these bugs will be fixed in a separate change. Notes: svn path=/head/; revision=251237
* Re-introduce another part of r249367. This commit fixes a register leak inMark Johnston2013-05-192-0/+85
| | | | | | | | | | | | | | | dt_cg_ptrsize() and generally cleans up some of the error handling around register allocation. This change corresponds to part of illumos-gate commit e5803b76927480: 3025 register leak in D code generation Reviewed by: pfg Obtained from: illumos MFC after: 1 month Notes: svn path=/head/; revision=250812
* Convert a couple of helper scripts used to test the ip provider to work onMark Johnston2013-05-152-11/+20
| | | | | | | | | | | FreeBSD. In the IPv6 case, try each interface before returning an error; each IPv6-enabled interface will have a link-local address even if the link isn't up. MFC after: 1 week Notes: svn path=/head/; revision=250685
* head -n doesn't take negative arguments on FreeBSD, so instead use sed '$d'Mark Johnston2013-05-122-4/+4
| | | | | | | to remove the last line of a file. Notes: svn path=/head/; revision=250575
* Bring back part of r249367 by adding DTrace's temporal option, which allowsMark Johnston2013-05-125-16/+271
| | | | | | | | | | | | | | | | | | | | | | | | | | | users to guarantee that the output of DTrace scripts will be time-ordered. This option is enabled by adding the line #pragma D option temporal to the beginning of a script, or by adding '-x temporal' to the arguments of dtrace(1). This change fixes a bug in the original port of the temporal option. This bug was causing some assertions to fail, so they had been disabled; in this revision the assertions are working properly and are enabled. The DTrace version number has been bumped from 1.9.0 to 1.9.1 to reflect the language change that's being introduced. This change corresponds to part of illumos-gate commit e5803b76927480: 3021 option for time-ordered output from dtrace(1M) Reviewed by: pfg Obtained from: illumos MFC after: 1 month Notes: svn path=/head/; revision=250574
* DTrace: Revert r249426Pedro F. Giffuni2013-04-1714-151/+18
| | | | | | | | | This change actually depends on r249367 which had to be reverted Pointy Hat: pfg Notes: svn path=/head/; revision=249575