Lines Matching refs:field
55 * Decode scope. When parsing a field that is itself a bitset, we push a
61 * But the field being resolved could be a derived field, or different
64 * triggers a recursive field lookup. But those lookups should not start
66 * prevents a field from accidentally resolving to different values
69 * wanted to optimize things by caching field lookup results.)
99 * be repeatedly evaluated for each field being resolved. And each
100 * field reference to a derived field (potentially from another expr)
370 /* When resolving a field for evaluating an expression,
401 extract_field(struct decode_scope *scope, const struct isa_field *field)
408 BITSET_SET_RANGE(mask.bitset, field->low, field->high);
410 BITSET_SHR(val.bitset, field->low);
459 * Decode a field that is itself another bitset type
462 display_bitset_field(struct decode_scope *scope, const struct isa_field *field, bitmask_t val)
464 const struct isa_bitset *b = find_bitset(scope->state, field->bitsets, val);
467 scope->bitset->name, field->name, BITSET_VALUE(val.bitset));
473 nested_scope->params = field->params;
479 display_enum_field(struct decode_scope *scope, const struct isa_field *field, bitmask_t val)
481 const struct isa_enum *e = field->enums;
502 const struct isa_field *field =
505 if (!field && scope->params) {
515 if (!field) {
519 /* extract out raw field value: */
520 if (field->expr) {
521 uint64_t val = evaluate_expr(scope, field->expr);
525 *valp = extract_field(scope, field);
528 return field;
536 const struct isa_field *field = resolve_field(scope, field_name, strlen(field_name), &val);
537 if (!field) {
538 decode_error(scope->state, "no field '%s'", field_name);
588 const struct isa_field *field = resolve_field(scope, field_name, field_name_len, &v);
589 if (!field) {
590 decode_error(scope->state, "no field '%.*s'", (int)field_name_len, field_name);
602 unsigned width = 1 + field->high - field->low;
607 switch (field->type) {
626 // TODO format # of digits based on field width?
648 if (field->display) {
650 print(scope->state, "%s", field->display);
657 display_enum_field(scope, field, v);
667 display_bitset_field(scope, field, v);
670 decode_error(scope->state, "Bad field type: %d (%s)",
671 field->type, field->name);