Project

General

Profile

Actions

Bug #7110

closed

EMG doesn't support modules leading to very many process instances

Added by Evgeny Novikov over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Immediate
Assignee:
Category:
Environment models
Target version:
-
Start date:
04/25/2016
Due date:
% Done:

0%

Estimated time:
Detected in build:
svn
Platform:
Published in build:
14d5a0f

Description

Instead it terminates with the exception like below:

2016-04-22 21:50:09 (components.py:100) EMG ERROR> Raise exception:
Traceback (most recent call last):
  File "/core/components.py", line 94, in run
    self.main()
  File "/core/utils.py", line 38, in callbacks_caller
    ret = attr(*args, **kwargs)
  File "/core/avtg/emg/__init__.py", line 60, in generate_environment
    tr.translate(mcs, model)
  File "/core/avtg/emg/translator/__init__.py", line 37, in translate
    self._generate_code(analysis, model)
  File "/core/avtg/emg/translator/sequential.py", line 111, in _generate_code
    base_list = self.__instanciate_processes(analysis, base_list, process)
  File "/core/avtg/emg/translator/sequential.py", line 218, in __instanciate_processes
    newp = self.__copy_process(instance)
  File "/core/avtg/emg/translator/sequential.py", line 179, in __copy_process
    format(int(self.conf["translation options"]["max instances number"])))
RuntimeError: EMG tries to generate more instances than it is allowed by configuration (300)

As far as I understand it was done to avoid bug #7037 but we can't leave this as is.

30 great modules from all Linux kernel modules are rejected by EMG due to this issue:
  1. drivers/atm/solos-pci.ko
  2. drivers/gpu/drm/i915/i915.ko
  3. drivers/gpu/drm/nouveau/nouveau.ko
  4. drivers/gpu/drm/radeon/radeon.ko
  5. drivers/hwmon/adm1026.ko
  6. drivers/hwmon/adt7475.ko
  7. drivers/hwmon/dme1737.ko
  8. drivers/hwmon/f71805f.ko
  9. drivers/hwmon/gl518sm.ko
  10. drivers/hwmon/it87.ko
  11. drivers/hwmon/lm63.ko
  12. drivers/hwmon/lm87.ko
  13. drivers/hwmon/lm93.ko
  14. drivers/hwmon/vt8231.ko
  15. drivers/hwmon/w83627hf.ko
  16. drivers/hwmon/w83781d.ko
  17. drivers/scsi/lpfc/lpfc.ko
  18. drivers/scsi/qla2xxx/qla2xxx.ko
  19. drivers/target/target_core_mod.ko
  20. fs/dlm/dlm.ko
  21. fs/ext4/ext4.ko
  22. fs/nfs/nfsv4.ko
  23. fs/nfsd/nfsd.ko
  24. fs/ocfs2/ocfs2.ko
  25. fs/xfs/xfs.ko
  26. net/bluetooth/bluetooth.ko
  27. net/ipv6/ipv6.ko
  28. net/mac80211/mac80211.ko
  29. net/sunrpc/sunrpc.ko
  30. net/wireless/cfg80211.ko

Besides EMG rejects one module from the validation set in such the way.


Related issues 2 (0 open2 closed)

Related to Klever - Bug #7133: EMG looses containers on stage of instanciating a processClosedIlja Zakharov04/27/2016

Actions
Blocked by Klever - Bug #7192: EMG works extremly slow on drivers/gpu/drm/gma500/gma500_gfx.koClosedIlja Zakharov05/11/2016

Actions
Actions #1

Updated by Evgeny Novikov over 8 years ago

  • Subject changed from EMG doesn't generate environment models for complex modules to EMG doesn't support modules leading to very many process instances
Actions #2

Updated by Ilja Zakharov over 8 years ago

In branch 'emg-array-instances' I drastically decreased number of instances using a completely different algorithm. By the way there are still very many of them can be generated for modules given in the list. So the problem is unfortunately still actual.

By the way EMG has performance problems iterating over call graph of such huge modules which also causes many troubles. So I am adding issue #7192 as a subtask, since it also prevents model generation for huge drivers.

Actions #3

Updated by Ilja Zakharov over 8 years ago

In the branch 'emg-performance-fixes' implemented several important optimizations which reduces number of instances, reduces memory usage and gives a considerable speed-up.

By the way the issue is not solved, since memory usage is high enough.

Actions #4

Updated by Evgeny Novikov over 8 years ago

  • Priority changed from High to Immediate

I merged the given branch to master in e3a3d1e since master doesn't likely work both with and without these optimizations. I just hope that it works better.

Actions #5

Updated by Ilja Zakharov over 8 years ago

Branch 'emg-performance-fixes' contains optimizations which drastically reduce time and memory usage in several times. For example 'drivers/net/ethernet/sfc/sfc.ko' driver can be verified with less than 300 megabytes used by EMG comparing with the recent value of 1,2Gb.

Also an environment model contains much less useless code than before.

Actions #6

Updated by Ilja Zakharov over 8 years ago

  • Status changed from New to Resolved
Actions #7

Updated by Evgeny Novikov over 8 years ago

  • Status changed from Resolved to Closed
  • Published in build set to 14d5a0f

The branch was merged to master in 14d5a0f. Let's hope that this will help!

Actions

Also available in: Atom PDF