Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
cmucl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Carl Shapiro
cmucl
Commits
13f41b9d
Commit
13f41b9d
authored
33 years ago
by
wlott
Browse files
Options
Downloads
Patches
Plain Diff
Initial revision
parent
61dea0a2
No related branches found
No related tags found
No related merge requests found
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
code/mach.lisp
+96
-0
96 additions, 0 deletions
code/mach.lisp
code/unix.lisp
+1575
-0
1575 additions, 0 deletions
code/unix.lisp
with
1671 additions
and
0 deletions
code/mach.lisp
0 → 100644
+
96
−
0
View file @
13f41b9d
;;; -*- Package: MACH -*-
;;;
;;; **********************************************************************
;;; This code was written as part of the CMU Common Lisp project at
;;; Carnegie Mellon University, and has been placed in the public domain.
;;; If you want to use this code or any part of CMU Common Lisp, please contact
;;; Scott Fahlman or slisp-group@cs.cmu.edu.
;;;
(
ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/mach.lisp,v 1.1 1992/01/24 04:31:37 wlott Exp $"
)
;;;
;;; **********************************************************************
;;;
;;; This file contains the low-level support for MACH features not found
;;; in UNIX.
;;;
(
in-package
"MACH"
)
(
use-package
"ALIEN"
)
(
use-package
"C-CALL"
)
(
use-package
"SYSTEM"
)
(
export
'
(
port
mach-task_self
mach-task_data
mach-task_notify
vm_allocate
vm_copy
vm_deallocate
vm_statistics
))
(
def-alien-type
port
int
)
;;;; Standard ports.
(
def-alien-routine
(
"task_self"
mach-task_self
)
int
)
(
def-alien-routine
(
"thread_reply"
mach-task_data
)
int
)
(
def-alien-routine
(
"task_notify"
mach-task_notify
)
int
)
;;;; VM routines.
(
export
'
(
vm_allocate
vm_copy
vm_deallocate
vm_statistics
))
(
def-alien-routine
(
"vm_allocate"
vm_allocate
)
int
(
task
port
)
(
address
system-area-pointer
:in-out
)
(
size
unsigned-long
)
(
anywhere
boolean
))
(
def-alien-routine
(
"vm_copy"
vm_copy
)
int
(
task
port
)
(
source
system-area-pointer
)
(
count
unsigned-long
)
(
dest
system-area-pointer
))
(
def-alien-routine
(
"vm_deallocate"
vm_deallocate
)
int
(
task
port
)
(
address
system-area-pointer
)
(
size
unsigned-long
))
(
def-alien-type
nil
(
struct
vm_statistics
(
pagesize
long
)
(
free_count
long
)
(
active_count
long
)
(
inactive_count
long
)
(
wire_count
long
)
(
zero_fill_count
long
)
(
reactivations
long
)
(
pageins
long
)
(
pageouts
long
)
(
faults
long
)
(
cow_faults
long
)
(
lookups
long
)
(
hits
long
)))
(
defun
vm_statistics
(
task
)
(
with-alien
((
vm_stats
(
struct
vm_statistics
)))
(
values
(
alien-funcall
(
extern-alien
"vm_statistics"
(
function
int
port
(
*
(
struct
vm_statistics
))))
task
(
alien-sap
vm_stats
))
(
slot
vm_stats
'pagesize
)
(
slot
vm_stats
'free_count
)
(
slot
vm_stats
'active_count
)
(
slot
vm_stats
'inactive_count
)
(
slot
vm_stats
'wire_count
)
(
slot
vm_stats
'zero_fill_count
)
(
slot
vm_stats
'reactivations
)
(
slot
vm_stats
'pageins
)
(
slot
vm_stats
'pageouts
)
(
slot
vm_stats
'faults
)
(
slot
vm_stats
'cow_faults
)
(
slot
vm_stats
'lookups
)
(
slot
vm_stats
'hits
))))
This diff is collapsed.
Click to expand it.
code/unix.lisp
0 → 100644
+
1575
−
0
View file @
13f41b9d
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment