ppc: model.lisp

PowerPC CPU models: the build's model, chosen at build time.

Other definitions

(defmacro ppc-model-case) source
(defmacro ppc-model-case (&rest clauses)
  (ppc-model-require)
  (let ((c (ppc-model-clause clauses (lambda (k) (eq k *ppc-model*)))))
    (and c `(progn ,@(cdr c)))))
(defmacro ppc-model-feature-case) source
(defmacro ppc-model-feature-case (&rest clauses)
  (ppc-model-require)
  (let ((c (ppc-model-clause clauses (lambda (k) (member k (getf *ppc-model-props* :features))))))
    (and c `(progn ,@(cdr c)))))
(defmacro ppc-model-value) source
(defmacro ppc-model-value (key)
  (ppc-model-require)
  (let ((v (getf *ppc-model-props* key :none)))
    (when (eq v :none)
      (error "the PowerPC model ~(~A~) has no ~S" *ppc-model* key))
    v))

Made from xspe at b2fac33349db by tools/gen-xspe.py. xspe is GPL-3.0-or-later.