hal/metal/msl/lowering.lisp
The Metal language policy selected for one direct shader lowering.
One rendered occurrence retaining its originating shader expression.
One rendered structure field retaining its shader declaration for #YA4KDP.
One entry-point parameter and the resource, if any, which produced it.
One local declaration retaining its semantic shader binding.
One output assignment retaining its semantic shader assignment.
Return the homogeneous quantity carried by origin.
Return the component quantity layout carried by origin.
Render one shader expression and retain a source occurrence for it.
Render one semantic shader-map application for MSL.
Lower ldb to a logical shift and mask in the operand's own width.
The shared camera graph intentionally retains Vulkan's framebuffer-oriented clip Y. Metal owns the target conversion.
Lower one semantic shader statement to structured MSL.
Lower the shared shader graph directly to a structured MSL document.
The Metal language policy selected for one direct shader lowering.
One rendered occurrence retaining its originating shader expression.
One rendered structure field retaining its shader declaration for #YA4KDP.
Headings, paragraphs, figures and their IDs, mentions, marks.
One entry-point parameter and the resource, if any, which produced it.
One local declaration retaining its semantic shader binding.
One output assignment retaining its semantic shader assignment.
(&body body)The declarations BODY makes, read as a rule body, for a rule to include: the way to write a mixin.
(context)A MuPDF context: its allocator, its store, and its error stack.
(name)Test whether two compatible scalars are equal.
Logical disjunction of tests and raw truth values.
Logical conjunction of tests and raw truth values.
(type &optional source-form)(designator &optional source-form)(name &optional suffix)(value)(name)(factor)(factors)(order)(specification)(specification)Whether SPECIFICATION's named definition declares a non-negative amount. Only a named absolute can promise this; anonymous derived results never do.
(specification)(dimension)(specification)(positions)(layout &key sampled-p)How the children of a list are arranged.
(origin)Return the homogeneous quantity carried by ORIGIN.
A represented shader value with optional backend-neutral semantic meaning.
(binding)A descriptor resource and, for textures, the represented meaning and colour transfer of the value returned by sampling.
(origin)Return the component quantity layout carried by ORIGIN.
(expression)(origin &key sampled-p unannotated-p)(origin stream indentation &key sampled-p unannotated-p)(line)(context expression text)(occurrence)(context expression)Render one shader EXPRESSION and retain a source occurrence for it.
(literal)(reference)A lexical alias for one already parsed shader-function argument.
(expression)(object)(operator context expression)Lower EXPRESSION into CONTEXT's target product and return its value. Target context deliberately precedes operator identity in method selection: an operator implemented only for one backend must not capture another backend's context before its source-located unsupported-operation method.
An inspectable typed call whose body is inlined during backend lowering.
A typed value conditional from the shared language.
A typed bounded fold lowered as structured target control flow.
(definition context application)Render one semantic shader-map application for MSL.
One top-level defining form of a source file.
The homogeneous result of applying a represented semantic map.
A four-row homogeneous map with a separately checked sampling projection.
A virtual sampling product projected from a homogeneous map application.
(context expression operand)A checked semantic name for a represented value, with no codegen effect.
(expression)An explicitly meaningful value constructed from semantically raw source.
(expression)An explicit assumption that an opaque represented value has a meaning.
(expression)An explicit exposure of a semantic value's raw machine representation.
(expression)An explicit linear unit conversion that may emit numerical scaling.
(expression)(expression)(context expression)(context expression operator)(context expression name)(context expression name)(operator text)Extract the unsigned bit field (BYTE SIZE POSITION) of one unsigned scalar.
An LDB call whose byte specifier is part of the operator, not an operand.
Addition over compatible quantities.
Subtraction or unary negation.
Multiplication and scalar scaling.
Division of two represented quantities.
The non-negative remainder of integer division.
Test whether one compatible scalar is less than another.
Test whether one compatible scalar is at most another.
Test whether one compatible scalar is greater than another.
Test whether one compatible scalar is at least another.
(operator name)The inner product of two vectors.
Interpolate compatible quantities by a scalar amount.
The componentwise absolute value of a raw value.
The componentwise square root of a raw value.
Raise a dimensionless value to a dimensionless power.
Constrain a quantity between compatible bounds.
Produce dimensionless progress across compatible edges.
Compare compatible quantities and produce dimensionless values.
Normalize a dimensionless vector.
(operator name)The minimum of compatible quantities.
The maximum of compatible quantities.
(context expression)(operator)Convert one scalar float or unsigned value to a 32-bit unsigned integer.
Convert one scalar float or unsigned value to a 64-bit unsigned integer.
Convert one scalar float or unsigned value to a 32-bit float.
Select and reorder vector components by a designator such as :XYZ or :RGB.
Sample a two-dimensional texture through a sampler at a UV coordinate.
Compare a depth reference through a comparison sampler at a UV coordinate.
Load one exact two-dimensional texel at an unsigned integer coordinate.
(stage declaration)PROPERTY: VALUES; -- the property a keyword, the values a list written space-separated.
(name suffix stage declarations)(stage declaration)(resource)(payload)(resource)(context specification input-parameter-name)One descriptor-backed uniform block with ordered, inspectable members.
(declaration stream)(statement stream)(stream &optional (extra 0))(declaration value)(condition)(stage)(entry-point stream)(document)An open document and the context it was opened in.
(specification)(context statement)Lower one semantic shader statement to structured MSL.
(context expression)(context values)(context specification)(context specification)(specification)(target specification context declarations entry-point)(target specification context)(stage specification)(stage payload)(target specification context)(topology)(target specification context)(target specification)Lower SPECIFICATION for TARGET without changing its source graph. TARGET participates in ordinary CLOS dispatch so each backend can own its structured product and source provenance. #JDLQPN
(specification &optional (target *metal-4-target*))(document pathname)Generated source is useful to read, but it is not a new semantic store. The MSL fields, parameters, local statements, and output statements retain the declaration, resource, binding, or assignment which produced them. Rendering asks those existing #C6E3LA objects for their quantity specification or component layout…
Direct Metal Shading Language lowering for luv's mathematical shaders.
The source shader graph stays unchanged. This sibling compiler produces a small structured document and records every rendered expression occurrence, rather than routing Metal through SPIR-V or accumulating one opaque string.