Omar Besbes

69 papers A* 18A 1Journal 48Unranked 2
YearRankTypeTitle / Venue / Authors
2026 A* conf
WWW
Amine Allouah, Omar Besbes, Josué D. Figueroa, Yash Kanoria, Akshit Kumar
2025 conf
EAAMO
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes, Bolun Xu
2025 A* conf
EC
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes, Bolun Xu
2025 J jnl
Manag. Sci.
Omar Besbes, Will Ma, Omar Mouchtaki
2025 J jnl
Oper. Res.
Omar Besbes, Yuri Fonseca, Ilan Lobel
2025 J jnl
Oper. Res.
Omar Besbes, Yash Kanoria, Akshit Kumar
2025 A* conf
EC
Omar Besbes, Yash Kanoria, Akshit Kumar
2025 J jnl
CoRR
Omar Besbes, Yash Kanoria, Akshit Kumar
2025 J jnl
Oper. Res.
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes
2025 J jnl
CoRR
Amine Allouah, Omar Besbes, Josué D. Figueroa, Yash Kanoria, Akshit Kumar
2024 J jnl
CoRR
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes, Bolun Xu
2024 J jnl
CoRR
Achraf Bahamou, Omar Besbes, Omar Mouchtaki
2024 J jnl
Oper. Res.
Santiago R. Balseiro, Omar Besbes, Francisco Castro
2024 J jnl
Oper. Res.
Santiago R. Balseiro, Omar Besbes, Dana Pizarro
2024 A conf
RecSys
Omar Besbes, Yash Kanoria, Akshit Kumar
2024 J jnl
CoRR
Omar Besbes, Yash Kanoria, Akshit Kumar
2024 J jnl
Manuf. Serv. Oper. Manag.
Omar Besbes, Vineet Goyal, Garud Iyengar, Raghav Singal
2023 J jnl
Manag. Sci.
Omar Besbes, Omar Mouchtaki
2023 J jnl
Manag. Sci.
Amine Allouah, Achraf Bahamou, Omar Besbes
2023 J jnl
CoRR
Omar Besbes, Will Ma, Omar Mouchtaki
2023 A* conf
EC
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes
2023 J jnl
CoRR
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes
2023 A* conf
EC
Omar Besbes, Yuri Fonseca, Ilan Lobel, Fanyin Zheng
2022 A* conf
NeurIPS
Omar Besbes, Will Ma, Omar Mouchtaki
2022 J jnl
CoRR
Omar Besbes, Will Ma, Omar Mouchtaki
2022 A* conf
EC
Jerry Anunrojwong, Santiago R. Balseiro, Omar Besbes
2022 J jnl
Oper. Res.
Amine Allouah, Achraf Bahamou, Omar Besbes
2022 J jnl
Manag. Sci.
Raghav Singal, Omar Besbes, Antoine Désir, Vineet Goyal, Garud Iyengar
2022 J jnl
Oper. Res.
Omar Besbes, Francisco Castro, Ilan Lobel
2022 J jnl
Oper. Res.
Omar Besbes, Adam N. Elmachtoub, Yunjie Sun
2022 A* conf
EC
Omar Besbes, Yash Kanoria, Akshit Kumar
2022 J jnl
CoRR
Omar Besbes, Yash Kanoria, Akshit Kumar
2021 J jnl
CoRR
Omar Besbes, Yuri Fonseca, Ilan Lobel
2021 A* conf
COLT
Omar Besbes, Yuri Fonseca, Ilan Lobel
2021 A* conf
EC
Amine Allouah, Achraf Bahamou, Omar Besbes
2021 J jnl
CoRR
Amine Allouah, Achraf Bahamou, Omar Besbes
2021 A* conf
EC
Amine Allouah, Achraf Bahamou, Omar Besbes
2021 J jnl
Manag. Sci.
Omar Besbes, Francisco Castro, Ilan Lobel
2020 J jnl
INFORMS J. Appl. Anal.
Omar Besbes, Adam N. Elmachtoub, Yunjie Sun
2020 J jnl
Manag. Sci.
Amine Allouah, Omar Besbes
2019 J jnl
Manag. Sci.
Tian Heong Chan, Francis de Véricourt, Omar Besbes
2019 J jnl
Oper. Res.
Santiago R. Balseiro, Omar Besbes, Gabriel Y. Weintraub
2019 A* conf
EC
Amine Allouah, Omar Besbes
2019 A* conf
WWW
Omar Besbes, Antoine Désir, Vineet Goyal, Garud Iyengar, Raghav Singal
2019 A* conf
EC
Omar Besbes, Francisco Castro, Ilan Lobel
2019 A* conf
EC
Omar Besbes, Adam N. Elmachtoub, Yunjie Sun
2019 J jnl
CoRR
Omar Besbes, Adam N. Elmachtoub, Yunjie Sun
2018 J jnl
Manag. Sci.
Omar Besbes, Dan Andrei Iancu, Nikolaos Trichakis
2018 J jnl
Oper. Res.
Omar Besbes, Marco Scarsini
2018 A* conf
EC
Amine Allouah, Omar Besbes
2016 A* conf
EC
Santiago R. Balseiro, Omar Besbes, Gabriel Y. Weintraub
2016 J jnl
Manuf. Serv. Oper. Manag.
Omar Besbes, Yonatan Gur, Assaf Zeevi
2015 J jnl
Manag. Sci.
Omar Besbes, Ilan Lobel
2015 J jnl
Oper. Res.
Omar Besbes, Yonatan Gur, Assaf Zeevi
2015 J jnl
Manag. Sci.
Omar Besbes, Assaf Zeevi
2015 J jnl
Manag. Sci.
Santiago R. Balseiro, Omar Besbes, Gabriel Y. Weintraub
2014 J jnl
Manuf. Serv. Oper. Manag.
Omar Besbes, Denis Sauré
2014 J jnl
CoRR
Omar Besbes, Yonatan Gur, Assaf Zeevi
2014 conf
NIPS
Yonatan Gur, Assaf Zeevi, Omar Besbes
2013 A* conf
EC
Santiago R. Balseiro, Omar Besbes, Gabriel Y. Weintraub
2013 J jnl
CoRR
Omar Besbes, Yonatan Gur, Assaf Zeevi
2013 J jnl
Manag. Sci.
Omar Besbes, Alp Muharremoglu
2012 J jnl
Oper. Res.
Omar Besbes, Assaf Zeevi
2012 J jnl
Manag. Sci.
Omar Besbes, Costis Maglaras
2011 J jnl
Oper. Res.
Omar Besbes, Assaf Zeevi
2010 J jnl
Manuf. Serv. Oper. Manag.
Omar Besbes, Robert Phillips, Assaf Zeevi
2009 J jnl
Oper. Res.
Omar Besbes, Assaf Zeevi
2009 J jnl
Manuf. Serv. Oper. Manag.
Omar Besbes, Sergei V. Savin
2009 J jnl
Oper. Res.
Omar Besbes, Costis Maglaras
tests/unit/test_decompile_function_type.py
← Index tests/unit/test_decompile_function_type.py python
"""Unit tests for bninja/function_type.py."""
import sys
import pytest
from unittest.mock import MagicMock

# Install binaryninja stubs before importing
from tests.unit.conftest_binja_stubs import install_binja_stubs, SymbolType
install_binja_stubs()

from redb.extractors.decompiler.bninja.function_type import (
    FunctionType,
    FunctionTypeAnalysis,
)


# ============================================================================
# 4a. FunctionType / FunctionTypeAnalysis
# ============================================================================


class TestFunctionTypeEnum:
    def test_function_type_enum_values(self):
        assert FunctionType.USER.value == "USER"
        assert FunctionType.LIBRARY.value == "LIBRARY"
        assert FunctionType.EXTERNAL.value == "EXTERNAL"
        assert FunctionType.THUNK.value == "THUNK"
        assert FunctionType.UNKNOWN.value == "UNKNOWN"


class TestFunctionTypeAnalysis:
    def _make_function(self, symbol_type=None, is_thunk=False, raise_on_symbol=False):
        func = MagicMock()
        func.is_thunk = is_thunk
        if raise_on_symbol:
            type(func).symbol = property(lambda self: (_ for _ in ()).throw(Exception("no symbol")))
        else:
            func.symbol.type = symbol_type if symbol_type is not None else SymbolType.FunctionSymbol
        return func

    def test_user_function_type(self):
        func = self._make_function(symbol_type=SymbolType.FunctionSymbol)
        analysis = FunctionTypeAnalysis(func)
        assert analysis.get_function_type() == FunctionType.USER

    def test_external_function_type(self):
        func = self._make_function(symbol_type=SymbolType.ImportedFunctionSymbol)
        analysis = FunctionTypeAnalysis(func)
        assert analysis.get_function_type() == FunctionType.EXTERNAL

    def test_library_function_type(self):
        func = self._make_function(symbol_type=SymbolType.LibraryFunctionSymbol)
        analysis = FunctionTypeAnalysis(func)
        assert analysis.get_function_type() == FunctionType.LIBRARY

    def test_thunk_function_type(self):
        # Thunk overrides the symbol type
        func = self._make_function(
            symbol_type=SymbolType.FunctionSymbol, is_thunk=True
        )
        analysis = FunctionTypeAnalysis(func)
        assert analysis.get_function_type() == FunctionType.THUNK

    def test_exception_returns_unknown(self):
        func = self._make_function(raise_on_symbol=True)
        analysis = FunctionTypeAnalysis(func)
        assert analysis.get_function_type() == FunctionType.UNKNOWN