Skip to content

FB_PROFILE


Intrinsic define set by the compiler

Syntax

` FB_PROFILE

`

Description

Intrinsic define set to an integer to indicate the profiling method.

The different value are defined in the ./inc/fbc-int/profile.bi include file (inside Namespace: FB and Enum: PROFGEN_ID):

  • PROFGEN_ID_NONE: profiling is not enabled
  • PROFGEN_ID_GMON: code is being generated for gmon/gprof
  • PROFGEN_ID_CALLS: code is being generated for fb's function call profiler
  • PROFGEN_ID_CYCLES: code is being generated for fb's cycle count call profiler

Examples

start GeSHi

vb
#cmdline "-profgen fb"
#include once "fbc-int/profile.bi"
Using FBC

Print "__FB_PROFILE__ = ";

Select Case __FB_PROFILE__
Case PROFGEN_ID_NONE
    Print "PROFGEN_ID_NONE"
Case PROFGEN_ID_GMON
    Print "PROFGEN_ID_GMON"
Case PROFGEN_ID_CALLS
    Print "PROFGEN_ID_CALLS"
Case PROFGEN_ID_CYCLES
    Print "PROFGEN_ID_CYCLES"
End Select

end GeSHi

Version

  • Since fbc 1.20.0

Differences from QB

  • New to FreeBASIC

See also

Back to DocToc

Translated from FreeBASIC official docs. Contact us for removal if infringed.
FreeBASIC is an open-source project, not affiliated with Microsoft