Lines Matching refs:bitwidth
404 def enumToValue(self, elem, needsNum, bitwidth = 32,
410 - bitwidth - size of the numeric representation in bits (32 or 64)
454 if bitwidth == 64:
465 if bitwidth == 64 or bitpos >= 32:
576 bitwidth = 32
580 bitwidth = 64
582 # Check for an explicitly defined bitwidth, which will override any defaults.
583 if groupElem.get('bitwidth'):
585 bitwidth = int(groupElem.get('bitwidth'))
587 self.logMsg('error', 'Invalid value for bitwidth attribute (', groupElem.get('bitwidth'), ') for ', groupName, ' - must be an integer value\n')
596 if bitwidth > 32 or self.misracppstyle():
602 # Validate the bitwidth and generate values appropriately
603 if bitwidth > 64:
604 self.logMsg('error', 'Invalid value for bitwidth attribute (', groupElem.get('bitwidth'), ') for bitmask type ', groupName, ' - must be less than or equal to 64\n')
607 return self.buildEnumCDecl_BitmaskOrDefine(groupinfo, groupName, bitwidth, usedefine)
609 # Validate the bitwidth and generate values appropriately
610 if bitwidth > 32:
611 self.logMsg('error', 'Invalid value for bitwidth attribute (', groupElem.get('bitwidth'), ') for enum type ', groupName, ' - must be less than or equal to 32\n')
616 def buildEnumCDecl_BitmaskOrDefine(self, groupinfo, groupName, bitwidth, usedefine):
625 if bitwidth == 64:
652 (numVal, strVal) = self.enumToValue(elem, True, bitwidth, True)
678 (numVal, strVal) = self.enumToValue(alias, True, bitwidth, True)