Commit Graph

437 Commits

Author SHA1 Message Date
briggs
0b956d0b8b Implement pmc(9) -- An interface to hardware performance monitoring
counters.  These counters do not exist on all CPUs, but where they
do exist, can be used for counting events such as dcache misses that
would otherwise be difficult or impossible to instrument by code
inspection or hardware simulation.

pmc(9) is meant to be a general interface.  Initially, the Intel XScale
counters are the only ones supported.
2002-08-07 05:14:47 +00:00
thorpej
011d4d5f44 Add kernel support for having userland provide the signal trampoline:
* struct sigacts gets a new sigact_sigdesc structure, which has the
  sigaction and the trampoline/version.  Version 0 means "legacy kernel
  provided trampoline".  Other versions are coordinated with machine-
  dependent code in libc.
* sigaction1() grows two more arguments -- the trampoline pointer and
  the trampoline version.
* A new __sigaction_sigtramp() system call is provided to register a
  trampoline along with a signal handler.
* The handler is no longer passed to sensig() functions.  Instead,
  sendsig() looks up the handler by peeking in the sigacts for the
  process getting the signal (since it has to look in there for the
  trampoline anyway).
* Native sendsig() functions now select the appropriate trampoline and
  its arguments based on the trampoline version in the sigacts.

Changes to libc to use the new facility will be checked in later.  Kernel
version not bumped; we will ride the 1.6C bump made recently.
2002-07-04 23:32:02 +00:00
yamt
d96bff0e27 add KSTACK_CHECK_MAGIC. discussed on tech-kern. 2002-07-02 20:27:44 +00:00
matt
4cfae24f91 Add -ffreestanding and LIBC= to stand/boot/*/Makefile. Fix various
asm's to work with gcc-current.
2002-06-09 19:21:07 +00:00
ragge
c691ddb3fb Repair VAX8600 support, which had bit-rotten, probably not used since -98. 2002-06-04 19:04:32 +00:00
ragge
787f3adbcf ALIGNENTRY must always be 0 on vax, otherwise loadfile_aout won't work. 2002-05-31 15:22:01 +00:00
matt
5916ff65fd Eliminate commons. 2002-05-13 21:11:23 +00:00
matt
0a6d35b7ed Nuke local extern label_t *db_recover; it's now in <ddb/db_extern.h> 2002-05-13 20:30:07 +00:00
thorpej
74e2ee8d5c Define __NO_STRICT_ALIGNMENT. 2002-05-02 16:11:28 +00:00
ragge
2d53738484 Cast some args to unsigned long (used with pointers). 2002-04-21 21:00:29 +00:00
ragge
205b746c87 Wrap up SHMMAXPGS to 1024, no reason to keep it low. 2002-04-01 13:28:10 +00:00
matt
015bf59476 Make ddb symbol loading work for ELF as well a.out. 2002-03-31 00:11:13 +00:00
matt
e00090dded Make the comment reflect reality a bit more. 2002-03-27 18:37:17 +00:00
jdolecek
abc9dff158 Limit the KVA used for pipe loaned memory to 64KB, vax doesn't have too
much KVA space spare. This fixes port-vax/13333 by Manuel Bouyer.
Reviewed by: Anders Magnusson

XXX this is not ideal, need to find better solution
2002-03-24 19:08:17 +00:00
ragge
c034dd5209 Inline functions that mostly do not need to be called. Partly
rearrange/change the code to be able to avoid some inefficient functions.
Profiling shows that the time spent in pmap now is decreased by 20%. (!)
2002-03-21 22:08:08 +00:00
ragge
fe503fb96f Major update of the vax pmap:
- Reinstall the "dynamic page table length" that was removed some
	  years ago.
	- Limit the user page table submap to max 5% of available memory.
	- Free the page table space when a process is swapped out.
	- If the UPT submap runs out of space, throw away pmap mappings
	  using the same algorithm as for swapping processes.

As a result of this, 4MB machines are useable again and it's even possible
to compile a kernel for 2MB machines (but it will be slow... :-)

Still to do:
	- Multiprocessor fixes.
	- More profiling.
2002-03-10 22:32:31 +00:00
ragge
16cd24dea4 usrptsize was not correct calculated, fixed.
Add space to system page table for the UVM kernel area.
This fixes the KVM usage problem that Manuel Bouyer reported a while ago.
2002-03-01 23:55:10 +00:00
simonb
4324f37586 Use "#define<tab>". 2002-02-28 03:17:23 +00:00
simonb
d9ab16ba2f Purge CLSIZE, CLSIZELOG2 and MCLOFSET.
Be consistant in the way that MSIZE, MCLSHIFT, MCLBYTES and NMBCLUSTERS
  are defined.
Remove old VM constants from cesfic port.
Bump MSIZE to 256 on mipsco (the only one that wasn't already 256).
2002-02-26 15:13:19 +00:00
matt
28b1aa2b30 Move .s files to .S files. (and .s.o rules in boot/Makefile.inc)
Put in register prefixes everywhere.
2002-02-24 01:04:23 +00:00
thorpej
9d6e94072b Bump the default data limit to 32M and the max data limit to 64M.
These are the same values that the hp300 port uses (lesser hp300s
have roughly the same memory constraints as "lesser" vaxen), and
bumping them allows us to run a statically linked ELF groff(1).
2002-02-19 22:44:35 +00:00
thorpej
30bdf5c12e * Add __unused__ attribute to inline functions.
* Call __blkclr() and __blkset() as appropriate.
2002-02-10 22:06:12 +00:00
matt
0dab9a35b5 #include <sys/types.h> in case this is included before that was. 2001-12-23 02:21:03 +00:00
thorpej
51535d4bf5 Add support for dumping ELF-cormat core files. 2001-12-09 23:05:56 +00:00
thorpej
2494c460a5 Use inline functions for the byte swap routines. Allows libc to build
again (-Wshadow).
2001-11-29 22:32:45 +00:00
soren
662f877587 MAXSLP is defined to be a machine-independent scheduling parameter,
so move it into sys/param.h.
2001-11-15 18:06:11 +00:00
thorpej
e727e3f180 Split elf32 vs. elf64 handling in loadfile(), including support for
each separately and explicitly.  BOOT_ELF is now BOOT_ELF32 and
BOOT_ELF64, and ELFSIZE should no longer be defined in loadfile_machdep.h.
2001-10-31 17:20:45 +00:00
chs
3628675acf implement pmap_wired_count(). 2001-09-24 01:48:15 +00:00
ragge
8199c6a469 Some ID strings + other consistency fixes, from Michael Kukat. 2001-09-18 16:41:25 +00:00
simonb
1bc6516acc Only define _BSD_WCHAR_T_ once. 2001-09-17 05:40:38 +00:00
ragge
482334fa14 Add bus_space_mmap(). 2001-09-16 20:39:02 +00:00
chris
0e7661f023 Update pmap_update to now take the updated pmap as an argument.
This will allow improvements to the pmaps so that they can more easily defer expensive operations, eg tlb/cache flush, til the last possible moment.

Currently this is a no-op on most platforms, so they should see no difference.

Reviewed by Jason.
2001-09-10 21:19:08 +00:00
simonb
023bdd2bf2 Use comments around the token after a #endif. 2001-08-31 04:44:54 +00:00
matt
218b61dcd1 Change clock_t and time_t to more LP64 friendly types. 2001-07-28 07:43:07 +00:00
matt
f47c5bbd3d Under ELF, change clock_t and time_t to int's (more LP64 friendly). 2001-07-28 05:04:45 +00:00
ragge
f5abeb5b4b Set MAXPHYS to 64k instead of 63k. 2001-07-27 12:58:21 +00:00
thorpej
babefc5331 Add BUS_DMA_READ and BUS_DMA_WRITE flags, that hint the back-end
at dmamap load time that the mapping will be used for a unidirectional
transfer of the specified direction.
2001-07-19 15:32:10 +00:00
wiz
e2eaa3b87a constraint, not contraint. 2001-06-21 12:15:03 +00:00
thorpej
8eb3b954f1 Don't need to prototype child_return() here, it's in <sys/proc.h>. 2001-06-14 22:56:55 +00:00
wiz
40ac848024 Fix various misspellings of compatible/compatibility. 2001-06-11 01:50:48 +00:00
ragge
f81f19e7b3 Add rudimentary multiprocessor support for DDB. 2001-06-04 21:37:11 +00:00
ragge
93ece82137 Check for console printf's in spinlocks, per discussion on tech-smp. 2001-06-04 15:37:05 +00:00
ragge
30e020fbaa The beginning of pmap locks. While here, some cleaning and KNF. 2001-06-04 15:36:00 +00:00
ragge
81d993ac3b Add splipi(). 2001-06-04 15:34:57 +00:00
ragge
da2e5c43e1 Add IPI_TBIA to flush the translation buffer. 2001-06-04 15:34:15 +00:00
ragge
e2f864bf95 Break out the MP-dependent calls. Add definitions for the IPI functions. 2001-06-03 15:12:57 +00:00
ragge
d0a8785b5e Add define for IPI vector. 2001-06-03 15:10:34 +00:00
ragge
8d7b76581f Implement spinlocks as subroutines instead of inlines.
Add SPINLOCK_SPIN_HOOK; the VAX has low-priority IPIs like Alpha.
2001-06-03 15:10:11 +00:00
ragge
6e219aa5a7 Add bbssi/bbcci (bit set/clear and branch interlocked) as inline functions. 2001-06-03 15:08:32 +00:00
mrg
67afbd6270 use _KERNEL_OPT 2001-05-30 11:57:16 +00:00