diff options
Diffstat (limited to 'bitbake/lib/bb/cooker.py')
| -rw-r--r-- | bitbake/lib/bb/cooker.py | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index 1625d3c158..d6e6919506 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py | |||
| @@ -1585,28 +1585,6 @@ class BBCooker: | |||
| 1585 | self.databuilder.reset() | 1585 | self.databuilder.reset() |
| 1586 | self.data = self.databuilder.data | 1586 | self.data = self.databuilder.data |
| 1587 | 1587 | ||
| 1588 | def server_main(cooker, func, *args): | ||
| 1589 | cooker.pre_serve() | ||
| 1590 | |||
| 1591 | if cooker.configuration.profile: | ||
| 1592 | try: | ||
| 1593 | import cProfile as profile | ||
| 1594 | except: | ||
| 1595 | import profile | ||
| 1596 | prof = profile.Profile() | ||
| 1597 | |||
| 1598 | ret = profile.Profile.runcall(prof, func, *args) | ||
| 1599 | |||
| 1600 | prof.dump_stats("profile.log") | ||
| 1601 | bb.utils.process_profilelog("profile.log") | ||
| 1602 | print("Raw profiling information saved to profile.log and processed statistics to profile.log.processed") | ||
| 1603 | |||
| 1604 | else: | ||
| 1605 | ret = func(*args) | ||
| 1606 | |||
| 1607 | cooker.post_serve() | ||
| 1608 | |||
| 1609 | return ret | ||
| 1610 | 1588 | ||
| 1611 | class CookerExit(bb.event.Event): | 1589 | class CookerExit(bb.event.Event): |
| 1612 | """ | 1590 | """ |
